SA Bugzilla – Bug 6191
failed to spawn...Insecure dependency...Util.pm
Last modified: 2009-12-17 09:27:41 UTC
SpamAssassin v3.0.0 alpha 2, Solaris 9 Sparc, Perl 5.8.8 I get the following log entries when trying to start spamd: Sep 2 13:30:09 localhost spamd[8560]: logger: removing stderr method Sep 2 13:30:39 localhost spamd[8560]: child process exited or timed out without signaling production of a PID file at /usr/local/bin/spamd line 2505. Sep 2 13:30:49 localhost spamd[8563]: util: failed to spawn a process: Insecure dependency in exec while running with -T switch at /usr/local/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/Util.pm line 1528. at /usr/local/lib/perl5/site_perl/5.8.8/Mail/SpamAssassin/Util.pm line 1433. Sep 2 13:30:49 localhost spamd[8562]: pyzor: [8563] error: exit 6
Are you using any special options for pyzor in your config file? Is any of the directories in your path or where pyzor resides world-writable?
(In reply to comment #1) > Are you using any special options for pyzor in your config file? Here are the pyzor options from local.cf: use_pyzor 1 pyzor_path /usr/local/bin/pyzor pyzor_options --homedir /etc/mail/spamassassin/.pyzor These settings worked fine in v3.2.5. > Is any of the directories in your path or where pyzor resides world-writable? No.
Bug 6191: Plugin/Pyzor.pm, 'pyzor_options' was not untainted Sending lib/Mail/SpamAssassin/Plugin/Pyzor.pm Committed revision 810895.
Created attachment 4531 [details] untaints pyzor_options Please try the attached patch (or grab the current SVN head).
That fixes the taint problem, but I'm still getting an error: Sep 3 09:26:54 localhost spamd[22192]: logger: removing stderr method Sep 3 09:27:24 localhost spamd[22192]: child process exited or timed out without signaling production of a PID file at /usr/local/bin/spamd line 2505. Sep 3 09:27:38 localhost spamd[22194]: pyzor: [22197] error: TERMINATED, signal 15 (000f) Sep 3 09:27:46 localhost spamd[22194]: spamd: server started on port 783/tcp (running version 3.3.0-alpha2) I am able to run Pyzor from the command line (I get a timeout error).
> That fixes the taint problem, but I'm still getting an error: > > Sep 3 09:26:54 localhost spamd[22192]: logger: removing stderr method > Sep 3 09:27:24 localhost spamd[22192]: child process exited or timed out > without signaling production of a PID file at /usr/local/bin/spamd line 2505. > Sep 3 09:27:38 localhost spamd[22194]: pyzor: [22197] error: TERMINATED, > signal 15 (000f) > Sep 3 09:27:46 localhost spamd[22194]: spamd: server started on port 783/tcp > (running version 3.3.0-alpha2) > > I am able to run Pyzor from the command line (I get a timeout error). Well, I don't see much that SA can do except abort the forked pyzor process after 15 seconds if it doesn't reply in this time. Get running the pyzor from a command line first, and only then try to wrestle with a plugin after the basics are right. Perhaps the problem is a firewall setting, or lack of a successful 'pyzor discover'.
closing...
(In reply to comment #6) > > That fixes the taint problem, but I'm still getting an error: > > > > Sep 3 09:26:54 localhost spamd[22192]: logger: removing stderr method > > Sep 3 09:27:24 localhost spamd[22192]: child process exited or timed out > > without signaling production of a PID file at /usr/local/bin/spamd line 2505. > > Sep 3 09:27:38 localhost spamd[22194]: pyzor: [22197] error: TERMINATED, > > signal 15 (000f) > > Sep 3 09:27:46 localhost spamd[22194]: spamd: server started on port 783/tcp > > (running version 3.3.0-alpha2) > > > > I am able to run Pyzor from the command line (I get a timeout error). > Well, I don't see much that SA can do except abort the forked pyzor > process after 15 seconds if it doesn't reply in this time. > Get running the pyzor from a command line first, and only then try to > wrestle with a plugin after the basics are right. Perhaps the problem > is a firewall setting, or lack of a successful 'pyzor discover'. I got the Pyzor problem fixed (it was the firewall): ornl71# pyzor --homedir=/usr/local/spamassassin/.pyzor ping public.pyzor.org:24441 (200, 'OK') I'm no longer seeing the pyzor errors but I still get the "child process exited" when starting spamd: ornl71# /etc/init.d/spamd start child process exited or timed out without signaling production of a PID file at /usr/local/bin/spamd line 2505. and from the log file: Sep 21 09:55:22 localhost spamd[24972]: logger: removing stderr method Sep 21 09:55:52 localhost spamd[24972]: child process exited or timed out without signaling production of a PID file at /usr/local/bin/spamd line 2505. Sep 21 09:56:41 localhost spamd[24974]: spamd: server started on port 783/tcp (running version 3.3.0-alpha2)
After further analysis, the problem is that the daemonize() function has a loop that waits 30 seconds for the server to signal that it has started. On my box (a slow box used for development) it takes almost a minute, so the loop times out and complains.
Do we increase the timeout for the startup of spamd?
(In reply to comment #10) > Do we increase the timeout for the startup of spamd? sure, why not. I can see the usefulness of that.
Thanks Larry for tracking this down. Bug 6191: takes almost a minute to start spamd on a slow machine, bump up the retry counter to 90 seconds Sending spamd/spamd.raw Committed revision 817311.
According to Bug 6258, a forked fresh child can take 109 seconds to respond to a parent process. I'm briefly re-opening this bug to document it, and to bump up the timer to 180 seconds (3 minutes). I'm open to suggestions on the exact value, I guess two minutes would probably be fine too.
This one is trivial: Bug 6191, Bug 6258: bump the timeout for a spawned spamd start to 3 minutes Sending spamd/spamd.raw Committed revision 891806.