After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 667875 - Connections should be stopped when computer is offline
Connections should be stopped when computer is offline
Status: RESOLVED FIXED
Product: evolution-data-server
Classification: Platform
Component: Mailer
3.4.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: evolution-mail-maintainers
Evolution QA team
evolution[imapx]
Depends on:
Blocks:
 
 
Reported: 2012-01-13 15:38 UTC by Milan Bouchet-Valat
Modified: 2012-07-01 08:34 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Milan Bouchet-Valat 2012-01-13 15:38:41 UTC
I noticed that sometimes, when the system goes offline for some reason, e.g. you shut down the WiFi, Evo doesn't kill all IMAP (via imapx) connections. This means you can have spinning operations in the status bar that will never succeed, while NetworkManager correctly reports no connection is alive. 
It can be a problem if you go back online not too long after disconnecting: the old connections are still hanging, and prevent the new ones from succeeding.

I'm not sure how to reproduce it as it doesn't happen all the time. I suspect that when the ping to the IMAP server is failing (not sure why), then it will not be stopped even when going offline. I can investigate more if you can give me directions.


This is with Evo 3.2.2 on Fedora 16.
Comment 1 Matthew Barnes 2012-01-13 16:04:29 UTC
The real problem is Camel doesn't always respond to the cancellation requests Evolution passes down to it via GCancellable.
Comment 2 Milan Crha 2012-04-17 06:23:34 UTC
Downstream bug report about the same from 3.4.0:
https://bugzilla.redhat.com/show_bug.cgi?id=812511

I found a way to reproduce this bug at will:
  1) Run evolution and test that it works normally
  2) Kill the network (I'm using RFKILL switch)
  3) Click "Send / Recieve" when network is down

Thread 5 (Thread 0x7f24caffd700 (LWP 21751))

  • #0 pthread_join
    at pthread_join.c line 93
  • #1 g_system_thread_wait
    at gthread-posix.c line 1158
  • #2 g_thread_join
    at gthread.c line 966
  • #3 imapx_server_dispose
    at camel-imapx-server.c line 5374
  • #4 g_object_unref
    at gobject.c line 2981
  • #5 connection_info_unref
    at camel-imapx-conn-manager.c line 112
  • #6 connection_info_unref
    at camel-imapx-conn-manager.c line 103
  • #7 g_list_foreach
    at glist.c line 900
  • #8 g_list_free_full
    at glist.c line 183
  • #9 camel_imapx_conn_manager_close_connections
    at camel-imapx-conn-manager.c line 722
  • #10 imapx_disconnect_sync
    at camel-imapx-store.c line 226
  • #11 camel_service_disconnect_sync
    at camel-service.c line 1186
  • #12 camel_offline_store_set_online_sync
    at camel-offline-store.c line 174
  • #13 mail_store_go_offline_thread
    at e-mail-store-utils.c line 188
  • #14 run_in_thread
    at gsimpleasyncresult.c line 861
  • #15 io_job_thread
    at gioscheduler.c line 177
  • #16 g_thread_pool_thread_proxy
    at gthreadpool.c line 309
  • #17 g_thread_proxy
    at gthread.c line 801
  • #18 start_thread
    at pthread_create.c line 309
  • #19 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 115

Thread 4 (Thread 0x7f24f3df6700 (LWP 21775))

  • #0 pthread_join
    at pthread_join.c line 93
  • #1 g_system_thread_wait
    at gthread-posix.c line 1158
  • #2 g_thread_join
    at gthread.c line 966
  • #3 imapx_server_dispose
    at camel-imapx-server.c line 5374
  • #4 g_object_unref
    at gobject.c line 2981
  • #5 connection_info_unref
    at camel-imapx-conn-manager.c line 112
  • #6 connection_info_unref
    at camel-imapx-conn-manager.c line 103
  • #7 g_list_foreach
    at glist.c line 900
  • #8 g_list_free_full
    at glist.c line 183
  • #9 camel_imapx_conn_manager_close_connections
    at camel-imapx-conn-manager.c line 722
  • #10 imapx_disconnect_sync
    at camel-imapx-store.c line 226
  • #11 camel_service_disconnect_sync
    at camel-service.c line 1186
  • #12 camel_offline_store_set_online_sync
    at camel-offline-store.c line 174
  • #13 mail_store_go_offline_thread
    at e-mail-store-utils.c line 188
  • #14 run_in_thread
    at gsimpleasyncresult.c line 861
  • #15 io_job_thread
    at gioscheduler.c line 177
  • #16 g_thread_pool_thread_proxy
    at gthreadpool.c line 309
  • #17 g_thread_proxy
    at gthread.c line 801
  • #18 start_thread
    at pthread_create.c line 309
  • #19 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 115

Thread 3 (Thread 0x7f24cb7fe700 (LWP 21790))

  • #0 __lll_lock_wait
    at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S line 136
  • #1 _L_lock_889
    from /lib64/libpthread.so.0
  • #2 __pthread_mutex_lock
    at pthread_mutex_lock.c line 86
  • #3 g_static_rec_mutex_lock
    at deprecated/gthread-deprecated.c line 712
  • #4 camel_service_lock
    at camel-service.c line 1241
  • #5 camel_imapx_store_get_server
    at camel-imapx-store.c line 174
  • #6 imapx_synchronize_sync
    at camel-imapx-folder.c line 625
  • #7 camel_folder_synchronize_sync
    at camel-folder.c line 4033
  • #8 refresh_folders_exec
    at mail-send-recv.c line 1038
  • #9 mail_msg_proxy
    at mail-mt.c line 423
  • #10 g_thread_pool_thread_proxy
    at gthreadpool.c line 309
  • #11 g_thread_proxy
    at gthread.c line 801
  • #12 start_thread
    at pthread_create.c line 309
  • #13 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 115

Thread 2 (Thread 0x7f24dadf6700 (LWP 21791))

  • #0 __lll_lock_wait
    at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S line 136
  • #1 _L_lock_889
    from /lib64/libpthread.so.0
  • #2 __pthread_mutex_lock
    at pthread_mutex_lock.c line 86
  • #3 g_static_rec_mutex_lock
    at deprecated/gthread-deprecated.c line 712
  • #4 camel_service_lock
    at camel-service.c line 1241
  • #5 camel_imapx_store_get_server
    at camel-imapx-store.c line 174
  • #6 imapx_synchronize_sync
    at camel-imapx-folder.c line 625
  • #7 camel_folder_synchronize_sync
    at camel-folder.c line 4033
  • #8 refresh_folders_exec
    at mail-send-recv.c line 1038
  • #9 mail_msg_proxy
    at mail-mt.c line 423
  • #10 g_thread_pool_thread_proxy
    at gthreadpool.c line 309
  • #11 g_thread_proxy
    at gthread.c line 801
  • #12 start_thread
    at pthread_create.c line 309
  • #13 clone
    at ../sysdeps/unix/sysv/linux/x86_64/clone.S line 115

Comment 3 Milan Crha 2012-05-03 08:52:53 UTC
A similar issue with offline state is in bug #646801, while about imapx not stopping correctly is addressed within bug #664639, which may or may not address this issue too.
Comment 4 Milan Bouchet-Valat 2012-05-14 14:14:45 UTC
In 3.4, a terrible regression has appeared with respect to this: now, if network is disconnected, Evo only half-detects it, and will hang *forever* trying to fetch IMAPX mail. More precisely, this happens when I use both the WiFi killswitch or the network indicator; it also happens when returning from suspend, which is very annoying since xkill is then the only way to stop Evolution (!).

The "Network outage" banner is shown, but the icon at the bottom-left corner says Evo is online, and the File menu has a "Go offline" item. A few seconds after going offline or returning from suspend, Evo fetches mail automatically, and the operation cannot be stopped.

Do you think this is related to bug #664639 mentioned above?
Comment 5 Milan Crha 2012-05-15 09:23:29 UTC
(In reply to comment #4)
> Do you think this is related to bug #664639 mentioned above?

It may depend on the actual backtrace, but I guess it's related. At least your first paragraph sounds like the exactly same thing.
Comment 6 Milan Bouchet-Valat 2012-07-01 08:34:13 UTC
OK, this must have been related, since it's fixed in 3.4.3. Thanks!