Red Hat Bugzilla – Bug 213705
startup too slow
Last modified: 2008-05-06 12:40:28 EDT
Description of problem:
Starting the setroubleshoot service takes longer than almost any other service.
For no good reason. This is practically an interactive application. All that
_should_ be needed at start time is to set the program up to monitor new events
and to install the icon in the task bar.
All other work should be deferred. Old messages should be looked for only when
they have to be displayed.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.start system with setroubleshoot enabled
I'll take a look at the start up time. For what it's worth the setroubleshootd
daemon is completely disconnected from the GUI, the service has zero involvement
with anything interactive, rather it's a monitoring service.
One possible reason for the slow start up might be a large database of previous
alerts which is read at start up. We could modify the loading of the database to
be postponed until the first avc is delivered by the audit subsystem (e.g. load
To help me diagnose why you're seeing long start up times could you tell me the
size of /var/lib/setroubleshoot/database.xml?
> size of /var/lib/setroubleshoot/database.xml?
The current size is 45k, 1006 lines. I don't know whether I removed anything
since the last boot.
Regardless, if the startup is currently parsing this file and the information
isn't used in this instance it should be changed.
this is a note to myself: the loading of the plugin's should be deferred along
with the database load until first use.
moved python module loading into child fork, start up time signficantly
improved. Now the only thing the service does is fork and return, all subsequent
processing occurs in the child process.
Reopening based on this IRC dialog:
(05:57:51 PM) foo: about the startup bug
(05:57:58 PM) foo: you just fork and return
(05:58:17 PM) foo: this alone isn't really helping much if you do work after forking
(05:58:36 PM) foo: since the problem we have is that the disk is too busy during
startup and we want to completely avoid using it
(05:58:47 PM) foo: so, do you actually delay work until it's needed?
(06:03:08 PM) jdennis: no, the fix does not include postponing disk activity, I
had thought the issue was percieved start up time, we can reopen the bug pending
a fix for delayed operations
(06:04:29 PM) foo: yes, please reopen
(06:04:41 PM) jdennis: done
(06:04:50 PM) foo: as I said, what is killing us at startup is not really CPU
(06:04:55 PM) foo: it's disk activity
(06:05:22 PM) foo: and here the goal must be to delay as much work which
requires loading anything from disk to a late point in time as possible
(06:06:21 PM) foo: CPU use is also important but it's secondary and just
backgrounding doesn't help here either
(06:09:31 PM) jdennis: I think we can easily attack the low hanging fruit of
postponing the reading and parsing of the XML database untill first access, that
We also load all the plugins which should wait for the first avc.
*** Bug 253758 has been marked as a duplicate of this bug. ***
Fedora apologizes that these issues have not been resolved yet. We're
sorry it's taken so long for your bug to be properly triaged and acted
on. We appreciate the time you took to report this issue and want to
make sure no important bugs slip through the cracks.
If you're currently running a version of Fedora Core between 1 and 6,
please note that Fedora no longer maintains these releases. We strongly
encourage you to upgrade to a current Fedora release. In order to
refocus our efforts as a project we are flagging all of the open bugs
for releases which are no longer maintained and closing them.
If this bug is still open against Fedora Core 1 through 6, thirty days
from now, it will be closed 'WONTFIX'. If you can reporduce this bug in
the latest Fedora version, please change to the respective version. If
you are unable to do this, please add a comment to this bug requesting
Thanks for your help, and we apologize again that we haven't handled
these issues to this point.
The process we are following is outlined here:
We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.
And if you'd like to join the bug triage team to help make things
better, check out http://fedoraproject.org/wiki/BugZappers
This bug is open for a Fedora version that is no longer maintained and
will not be fixed by Fedora. Therefore we are closing this bug.
If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen thus bug against that version.
Thank you for reporting this bug and we are sorry it could not be fixed.