Re: losing STDIN
*** Karstens Rage escribió/wrote (Wed, 13 Sep 2006 09:37:56 -0700):
tail -n0 -F /var/log/mystuff.log | php -c /etc/php.ini myscript.php &
Everything works fine until logrotate rotates mystuff.log. Then the
script just hangs there and no longer processes anything.
I believe you can configure logrotate to shut down you script and launch it
again. That's what allows, for instance, to get Apache logs rotated. Could
that be a solution?
--
-+
http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
++ Mi sitio sobre programación web:
http://bits.demogracia.com
+- Mi web de humor con rayos UVA:
http://www.demogracia.com
--
.
Relevant Pages
- losing STDIN
... Zend Engine v2.0.4-dev, ... I wrote a script which basically sits in a while loop doing: ... Everything works fine until logrotate rotates mystuff.log. ... It doesn't seem to drop out of the while loop but I have to put some more debugging statements in to see if I can figure out what is going on. ... (comp.lang.php) - Re: Script hangs, but only one one machine
... The following test-script hangs for around 15 second at two steps. ... The script hangs around 15 seconds after "Setze Umgebungsvariable" and another 15 seconds after "Starte wscript.network zum Setzen des ... "in a timely manner" (even if that program has not asked for the notification), your script hangs until the notification times out. ... (microsoft.public.scripting.wsh) - Re: expect + telnet hangs on AIX
... Is it only telnet to a particular host that misbehaves? ... >> This script hangs 80% of the time ... >> When running expect -d it never hangs ... 'close stdout ' ... (comp.lang.tcl) - Re: ExecQuery hangs whole script but GetObject is fine
... Please can you write a small script that attempts this ExecQuery, ... ensure it hangs three times on the rogue machine and works three times ... > executing the query and the query hangs and thus the whole script ... > of the DCs as a domain admin but in the scheduled task that the script ... (microsoft.public.win32.programmer.wmi) - Re: T2000 wont shutdown
... few scripts later S91afbinit hangs. ... Killing that, and then S91zuluinit hangs. ... last one that's responsible for the script still running. ... Now it won't boot :-( A boot -s doesn't work either, ... (comp.unix.solaris) |
|