Bug 883410 - [abrt] File description leak from e_source_registry_authenticate_sync()
Summary: [abrt] File description leak from e_source_registry_authenticate_sync()
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: evolution
Version: 18
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Matthew Barnes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:9c25967246c4d563e9bef7c61b3...
: 883826 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-04 14:18 UTC by Brian J. Murrell
Modified: 2013-01-12 01:32 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-01-12 01:32:39 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: core_backtrace (1.83 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: environ (2.75 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: limits (1.29 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: backtrace (118.87 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: cgroup (128 bytes, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: xsession_errors (94.24 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: executable (18 bytes, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: maps (136.30 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: dso_list (29.21 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: build_ids (11.01 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: proc_pid_status (941 bytes, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: open_fds (48.56 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details
File: var_log_messages (1.45 KB, text/plain)
2012-12-04 14:18 UTC, Brian J. Murrell
no flags Details

Description Brian J. Murrell 2012-12-04 14:18:11 UTC
Version-Release number of selected component:
evolution-3.6.2-3.fc18

Additional info:
libreport version: 2.0.18
abrt_version:   2.0.18
backtrace_rating: 4
cmdline:        evolution
crash_function: g_wakeup_new
kernel:         3.6.8-2.fc17.x86_64

truncated backtrace:
:Thread no. 1 (9 frames)
: #2 g_wakeup_new at gwakeup.c:163
: #3 g_main_context_new at gmain.c:590
: #4 async_closure_new at camel-service.c:127
: #5 camel_service_connect_sync at camel-service.c:1597
: #6 imapx_refresh_info_sync at camel-imapx-folder.c:619
: #7 camel_folder_refresh_info_sync at camel-folder.c:3991
: #8 refresh_folders_exec at mail-send-recv.c:1049
: #9 mail_msg_proxy at mail-mt.c:423
: #11 g_thread_proxy at gthread.c:797

Comment 1 Brian J. Murrell 2012-12-04 14:18:14 UTC
Created attachment 657547 [details]
File: core_backtrace

Comment 2 Brian J. Murrell 2012-12-04 14:18:16 UTC
Created attachment 657548 [details]
File: environ

Comment 3 Brian J. Murrell 2012-12-04 14:18:18 UTC
Created attachment 657549 [details]
File: limits

Comment 4 Brian J. Murrell 2012-12-04 14:18:22 UTC
Created attachment 657550 [details]
File: backtrace

Comment 5 Brian J. Murrell 2012-12-04 14:18:25 UTC
Created attachment 657551 [details]
File: cgroup

Comment 6 Brian J. Murrell 2012-12-04 14:18:28 UTC
Created attachment 657552 [details]
File: xsession_errors

Comment 7 Brian J. Murrell 2012-12-04 14:18:29 UTC
Created attachment 657553 [details]
File: executable

Comment 8 Brian J. Murrell 2012-12-04 14:18:32 UTC
Created attachment 657554 [details]
File: maps

Comment 9 Brian J. Murrell 2012-12-04 14:18:34 UTC
Created attachment 657555 [details]
File: dso_list

Comment 10 Brian J. Murrell 2012-12-04 14:18:36 UTC
Created attachment 657556 [details]
File: build_ids

Comment 11 Brian J. Murrell 2012-12-04 14:18:38 UTC
Created attachment 657557 [details]
File: proc_pid_status

Comment 12 Brian J. Murrell 2012-12-04 14:18:40 UTC
Created attachment 657558 [details]
File: open_fds

Comment 13 Brian J. Murrell 2012-12-04 14:18:42 UTC
Created attachment 657559 [details]
File: var_log_messages

Comment 14 Milan Crha 2012-12-04 19:06:10 UTC
Thanks for a bug report. I recall something similar, which showed when evolution got out of file descriptors, which seems like it's leaking them somewhere. I know of one possible place [1], which is fixed for 3.6.3, but maybe there are more places.

Did you have evolution opened for a long(er) time, reading many emails? I'm just looking for a confirmation.

[1] http://git.gnome.org/browse/evolution/commit/?h=gnome-3-6&id=c7f5afb6d917

Comment 15 Brian J. Murrell 2012-12-04 19:56:04 UTC
(In reply to comment #14)
> Thanks for a bug report. I recall something similar, which showed when
> evolution got out of file descriptors, which seems like it's leaking them
> somewhere. I know of one possible place [1], which is fixed for 3.6.3,

Would be nice to get that into FC18 then.

> Did you have evolution opened for a long(er) time, reading many emails?

Well, certainly not as long as I have had 3.4.x open on FC17 since I only just updated to FC18 on the weekend and most certainly have restarted evolution in the last 24-48h.  I typically leave evolution open all of the time so on 3.4.x I would have easily had it open for many many days.

Comment 16 Milan Crha 2012-12-05 07:59:51 UTC
Could you try with this [1] scratch build, please? It contains the patch, it-ll be interesting to see whether it'll help for you. I'm not sure, because the file from comment #12 lists 1024 opened files, but most of them are "eventfd", which I do not know what exactly is.

[1] http://koji.fedoraproject.org/koji/taskinfo?taskID=4758366

Comment 17 Brian J. Murrell 2012-12-05 12:18:56 UTC
(In reply to comment #16)
> Could you try with this [1] scratch build,

Installed.  I will update if it crashes again.

Comment 18 Brian J. Murrell 2012-12-06 15:29:07 UTC
(In reply to comment #17)
>
> Installed.  I will update if it crashes again.

Crashed again last night.

Comment 19 Brian J. Murrell 2012-12-07 14:58:47 UTC
What can we do to make progress on this issue since this is a daily crasher in FC18?

Comment 20 Milan Crha 2012-12-10 10:16:30 UTC
*** Bug 883826 has been marked as a duplicate of this bug. ***

Comment 21 Milan Crha 2012-12-10 10:32:59 UTC
The key thing is to find out what is leaking the file descriptor(s), aka after which action the count of used file descriptors increases. Let's try this:
a) run evolution as usual
b) keep it running for awhile, say until the initial folder updates are done
c) then grab list of opened files with command:
   $ lsof -p `pidof evolution` >first.log
   get also count of lines, with this command:
   $ lsof -p `pidof evolution` | wc -l
d) do some action, like move from one message to another, move from one
   folder to another, and so on. When the status bar vanishes, check
   count of opened files:
   $ lsof -p `pidof evolution` | wc -l
   in case it increased from step c), then get list of opened files again:
   $ lsof -p `pidof evolution` >second.log

Diff of the first.log and the second.log may show what file is newly opened. Note some file handles can be left opened during message preview, and are freed only after you move to other message or folder.

Comment 22 Brian J. Murrell 2012-12-11 11:39:24 UTC
It looks like about 1 new eventfd gets created every minute without me even doing anything with evolution.  I do have it set to do an POP3 every minute as well as some IMAPX accounts also set on 1 minute polls although those IMAPX accounts are set:
* not to check all folders
* not to check subscribed folders
* use quick resync
* listen for server change notifications

And there is an EWS account set to poll every minute also but it also doesn't have the option to check all folders set.

I did a little experiment where I set just the pop3 account to check every 10 minutes and it definitely reduced the 1-per-minute eventfd creation.

Comment 23 Milan Crha 2012-12-12 12:11:05 UTC
Thanks a lot for the investigation. I can reproduce this too, whenever I do Send/Receive-><my POP3 account>, count of opened file descriptors increases by one. I'm investigating further.

Comment 24 Brian J. Murrell 2012-12-12 16:16:42 UTC
Happy to have helped.  Awesome that you can reproduce.

Comment 25 Milan Crha 2012-12-12 22:02:01 UTC
OK, after basically whole day of debugging I found out that the issue is that a GWakeUp a leaked. It's pretty hard to explain, but I tried within an upstream bug [1], after chat with other smart people. I'll try to find some easy workaround for this and apply it. (Interesting the GWakeUp failed because other instances of the same object were leaking.) :)

[1] https://bugzilla.gnome.org/show_bug.cgi?id=690126

Comment 26 Milan Crha 2012-12-12 22:45:11 UTC
I made upstream commits for 3.7.3+ and 3.6.3+ with a workaround. I'm also building an update of evolution-data-server with this workaround included, it'll be available for testing shortly. Thanks for your help with this.

Comment 27 Fedora Update System 2012-12-12 22:59:36 UTC
evolution-data-server-3.6.2-3.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/evolution-data-server-3.6.2-3.fc18

Comment 28 Fedora Update System 2012-12-14 06:46:03 UTC
Package evolution-data-server-3.6.2-3.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing evolution-data-server-3.6.2-3.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-20322/evolution-data-server-3.6.2-3.fc18
then log in and leave karma (feedback).

Comment 29 Brian J. Murrell 2012-12-17 00:16:19 UTC
(In reply to comment #28)
> Package evolution-data-server-3.6.2-3.fc18:

I had installed this and was using it at the end of last week however now evolution is segfaulting on startup and I can'f file an abrt dump because abrt can't find the debug packages for this e-d-s.

Comment 30 Milan Crha 2012-12-17 10:58:23 UTC
You can install debuginfo from the update by hand, when you download it and install with yum. The package is the same as the one before, only with a patch for this particular issue included. I hope you get some old issue, not a new caused by the update.

Comment 31 Milan Crha 2012-12-17 13:57:43 UTC
I see you managed to file the bug #887350 with abrt.

Comment 32 Fedora Update System 2013-01-12 01:32:40 UTC
evolution-data-server-3.6.2-3.fc18 has been pushed to the Fedora 18 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.