Nautilus hangs occationally while ejecting a media
- From: Narayana Pattipati <narayana pattipati wipro com>
- To: Desktop-Devel-List <desktop-devel-list gnome org>
- Subject: Nautilus hangs occationally while ejecting a media
- Date: Tue, 24 Dec 2002 17:07:58 +0530
Hi,
Nautilus is hanging occationally If I do eject on a media icon on
nautilus desktop for 5-6 times in a row. This is happening on Solaris-9
machine, and not on Solaris-8. (This may be because of the difference in
the thread implementation between S9 ans S8).
Looking at the code,
nautilus-volume-monitor.c: mount_unmount_callback (this is a thread
callback spawned by nautilus for doing mount/unmount/eject on a media)
if (info->command != NULL) {
open_error_pipe ();
file = popen (info->command, "r");
close_error_pipe (info->should_mount,
info->mount_point);
pclose (file);
g_free (info->command);
}
if (info->should_eject) {
eject_device
(info->device_path?info->device_path:info->mount_point);
}
For fixing bugzilla bug http://bugzilla.gnome.org/show_bug.cgi?id=96143
, I have modified the above code to Eject a media directly instead of
unmounting and then ejecting.
if (info->should_eject) {
eject_device
(info->device_path?info->device_path:info->mount_point);
} else {
if (info->command != NULL) {
open_error_pipe ();
file = popen (info->command, "r");
close_error_pipe (info->should_mount,
info->mount_point);
pclose (file);
g_free (info->command);
}
}
With this new code I am finding that nautilus is hanging occationally.
I could not fully understand the root cause for nautilus hang. But this
is happening because of the asynchronous execution of Eject
command(inside eject_device func.). If I replace the async execution of
Eject with a sync call (with popen() ) I don't see the hang. Note that
nautilus is doing all this in a separate thread created for just doing
mount/unmount/eject. Another interesting point is, in the same thread
callback, mount/unmount are executed synchronously using popen(). Why do
we need an async Eject command execution in a thread when the thread is
executing just one command.?
I am attaching the pstack of nautilus hang in S9 and pstack of working
nautilus in S8.
Could someone help me in figuring out the root cause for nautilus hang
in this case.?
Thanks,
Narayana
22100: nautilus --no-default-window --sm-client-id default3
----------------- lwp# 1 / thread# 1 --------------------
fe69ae00 poll (ffbfe4a8, 1, ffffffff)
fe64d474 _select (ffffffff, fe6bd19c, 0, fe6bd19c, ffbfe5a0, ffffffff) + 2ec
fe8cec7c select (5, ffbfe5a0, 0, 0, 0, ffbfe629) + 6c
fe71b728 _XWaitForReadable (0, ffbfe5a0, 20, ffbfebf8, ffbfea9c, 2) + e0
fe71b558 _XRead (a3918, ffbfe748, 20, ffbfe6e4, 3, 3007) + e8
fe71c488 _XReply (a3918, ffbfe748, 0, 1, 2, 202007) + 110
fe736770 XQueryPointer (a3918, 800e8e, ffbfe7e0, ffbfe7dc, ffbfe7d8, ffbfe7d4) + 90
fec57278 _gdk_windowing_window_get_pointer (3fc1f0, ffbfe874, ffbfe870, 0, ad5f0, 3fc250) + 198
fedf4170 gtk_menu_handle_scrolling (3c0450, 0, 329, 170a08, ad510, fef64b34) + 48
fedf46d4 gtk_menu_leave_notify (3c0450, 196a38, 112a10, 1704e0, 3c0450, fef64b34) + 84
fedeb618 _gtk_marshal_BOOLEAN__BOXED (fd2d8, 179614, 112a10, ffbfebf8, 3c0450, fedf4650) + 104
fe8fb54c g_closure_invoke (fd2d8, ffbfeab0, 2, ffbfebf8, ffbfea9c, 2) + 1a8
fe91339c signal_emit_unlocked_R (151b10, fe882d54, fe882d58, fe882d50, 0, fe93aa4c) + 1308
fe911660 g_signal_emit_valist (0, ffbfec10, ffbfee28, fe93aa4c, fdaa0, fe882d58) + 6b4
fee34f0c gtk_signal_emit (3c0450, 38, 196a38, 12fcb4, ad510, fef64b34) + 98
feed95e8 gtk_widget_event_internal (3c0450, 196a38, feed9388, 1a4, 30, 1e) + 1d8
fedea194 gtk_main_do_event (0, 196a38, fc00, 3c0450, ffef, 3e10) + 458
fec402a4 gdk_event_dispatch (af790, 1290, 196a38, fec7c0f0, ad190, fe882d50) + ac
fe827e8c g_main_dispatch (af800, fe8d2a50, 1000, 0, fe880520, af808) + 17c
fe8291f4 g_main_context_dispatch (af800, 1, fe882d54, 101c, fe882d50, 0) + a8
fe829604 g_main_context_iterate (af800, 1, 1, 1, af808, 2f7c80) + 3a4
fe829f10 g_main_loop_run (199d68, 1000, 0, fe882d54, 95c78, fe882d58) + 300
fede94e8 gtk_main (1, 0, 199d68, 3400, fef76c48, 0) + f8
00030740 main (71c00, ffbff2dc, c2590, 71dd0, 71dbc, 9bdc0) + 42c
00028850 _start (0, 0, 0, 0, 0, 0) + 108
----------------- lwp# 2 / thread# 2 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (190410, fe8e8b48, 0, 0, fe100200, fe8e8000) + d4
fe8d38a0 cond_wait (190410, 10d348, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (10d328, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (10d328, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (19ab50, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 3 / thread# 3 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (190458, fe8e8b48, 0, 0, fe100400, fe8e8000) + d4
fe8d38a0 cond_wait (190458, 10d3e8, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (10d3c8, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (10d3c8, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (19ac68, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 4 / thread# 4 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (1e3058, fe8e8b48, 0, 0, fe100600, fe8e8000) + d4
fe8d38a0 cond_wait (1e3058, 1e0a50, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (1e0a30, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (1e0a30, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (1e41d0, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 5 / thread# 5 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (1e6a98, fe8e8b48, 0, 0, fe100800, fe8e8000) + d4
fe8d38a0 cond_wait (1e6a98, 1e5918, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (1e58f8, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (1e58f8, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (1e45e0, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 6 / thread# 6 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (1e6b10, fe8e8b48, 0, 0, fe100a00, fe8e8000) + d4
fe8d38a0 cond_wait (1e6b10, 1e59d8, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (1e59b8, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (1e59b8, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (1e46d0, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 7 / thread# 7 --------------------
fe8d5dd4 lwp_park (0, 0, 0)
fe8d30e4 cond_wait_queue (1e6b70, fe8e8b48, 0, 0, fe100c00, fe8e8000) + d4
fe8d38a0 cond_wait (1e6b70, 1e5a78, fe8d25c4, fe882d58, b74, 800) + 14
feb08a08 gnome_vfs_thread_pool_wait_for_work (1e5a58, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (1e5a58, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (1e47e8, 1, fe882d58, fe882d54, fe8d2a50, feb08a54) + 13c
fe8d5c94 _lwp_start (0, 0, 0, 0, 0, 0)
----------------- lwp# 8 / thread# 8 --------------------
ff2fcc10 mount_unmount_callback(), exit value = 0x00000000
** zombie (exited, not detached, not yet joined) **
----------------- lwp# 9 / thread# 9 --------------------
ff2fcc10 mount_unmount_callback(), exit value = 0x00000000
** zombie (exited, not detached, not yet joined) **
----------------- lwp# 10 / thread# 10 --------------------
ff2fcc10 mount_unmount_callback(), exit value = 0x00000000
** zombie (exited, not detached, not yet joined) **
----------------- lwp# 11 / thread# 11 --------------------
ff2fcc10 mount_unmount_callback(), exit value = 0x00000000
** zombie (exited, not detached, not yet joined) **
----------------- lwp# 12 / thread# 12 --------------------
ff2fcc10 mount_unmount_callback(), exit value = 0x00000000
** zombie (exited, not detached, not yet joined) **
14778: nautilus --no-default-window --sm-client-id default3
----------------- lwp# 1 / thread# 1 --------------------
fe69d190 poll (2b6960, b, 7d0)
fe8caee8 poll (fe8cb998, 7d0, 7fffffff, 2b6960, b, fe880520) + 34
fe8295dc g_main_context_iterate (aec18, 1, 1, 0, aec20, 2b6960) + 37c
fe829f10 g_main_loop_run (172ca0, 1000, 0, fe882d54, 95f10, fe882d58) + 300
fede94e8 gtk_main (1, 0, 172ca0, 3400, fef76c48, 0) + f8
00030740 main (71c00, ffbef554, ecf00, 71dd0, 71dbc, 9c058) + 42c
00028850 _start (0, 0, 0, 0, 0, 0) + 108
----------------- lwp# 2 / thread# 2 --------------------
fe69e954 signotifywait ()
fe8bed54 _dynamiclwps (fe8de000, 59, 0, 0, ffbeee64, 4) + 1c
fe8c2030 thr_yield (0, 0, 0, 0, 0, 0) + 8c
----------------- lwp# 3 / thread# 4 --------------------
fe69f004 lwp_sema_wait (fde0be30)
fe8b9ac4 _park (fde0be30, fe8de000, 0, fde0bd70, 24d84, fdd09d70) + 114
fe8b978c _swtch (fde0bd70, 0, fe8de000, 5, 1000, 0) + 424
fe8b826c cond_wait (fde0bd70, 0, 0, fe8de000, 0, 170ab8) + 13c
feb08a08 gnome_vfs_thread_pool_wait_for_work (aef18, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (aef18, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (171518, 1, fe882d58, fe882d54, fe8cb998, feb08a54) + 13c
fe8cb728 _thread_start (171518, 0, 0, 0, 0, 0) + 40
----------------- lwp# 4 / thread# 6 --------------------
fe69f004 lwp_sema_wait (fdd09e30)
fe8b9ac4 _park (fdd09e30, fe8de000, 0, fdd09d70, 24d84, 0) + 114
fe8b978c _swtch (fdd09d70, 0, fe8de000, 5, 1000, 0) + 424
fe8b826c cond_wait (fdd09d70, 0, 0, fe8de000, 0, 28b428) + 13c
feb08a08 gnome_vfs_thread_pool_wait_for_work (28b408, b7c, 1abc0, fe882d54, 800, feb2353c) + 90
feb08aac thread_entry (28b408, 9bc, feb12e88, feb12e50, feb12e5c, feb2353c) + 58
fe843cd0 g_thread_create_proxy (27ce00, 1, fe882d58, fe882d54, fe8cb998, feb08a54) + 13c
fe8cb728 _thread_start (27ce00, 0, 0, 0, 0, 0) + 40
----------------- lwp# 5 --------------------------------
fe69c4f8 door (0, 0, 0, 0, fe055d10, 4)
fe8c6ba4 _sc_door_func (0, 0, 0, 0, 0, 0) + 54
-------------------------- thread# 3 --------------------
fe8bddbc _reap_wait (fe8e29e0, 20520, 0, fe8de000, 0, 0) + 38
fe8bdb14 _reaper (fe8dee30, fe8e4740, fe8e29e0, fe8dee08, 1, fe400000) + 38
fe8cb728 _thread_start (0, 0, 0, 0, 0, 0) + 40
-------------------------- thread# 5 --------------------
fe8cb6e0 _restorefsr (28b248, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 7 --------------------
fe8cb6e0 _restorefsr (2a2530, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 8 --------------------
fe8cb6e0 _restorefsr (3583a8, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 9 --------------------
fe8cb6e0 _restorefsr (2bb970, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 10 --------------------
fe8cb6e0 _restorefsr (2792b0, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 11 --------------------
fe8cb6e0 _restorefsr (2a9050, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 12 --------------------
fe8cb6e0 _restorefsr (2779c8, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 13 --------------------
fe8cb6e0 _restorefsr (2b8910, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 14 --------------------
fe8cb6e0 _restorefsr (37f858, 0, 0, 0, 0, 0) + 8
-------------------------- thread# 15 --------------------
fe8cb6e0 _restorefsr (2c4fe8, 0, 0, 0, 0, 0) + 8
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]