Bug #15926 [Csd->Opn]: can't pid file option setting
| From: | neta-master at ywcafe dot net | Date: | Mon, 23 Feb 2009 13:22:04 +0000 |
| Subject: | Bug #15926 [Csd->Opn]: can't pid file option setting | ||
| References: | 1 | Groups: | php.pear.bugs |
| Request: | Send a blank email to pear-bugs+get-69@lists.php.net to get a copy of this message | ||
Edit report at http://pear.php.net/bugs/bug.php?id=15926&edit=1
ID: 15926
Updated by: neta-master@ywcafe.net
Reported By: neta-master at ywcafe dot net
Summary: can't pid file option setting
-Status: Closed
+Status: Open
Type: Bug
Package: System_Daemon
Operating System: Linux
PHP Version: 5.2.5
Assigned To: kvz
Roadmap Versions:
New Comment:
<div id="changeset">
<span class="removed">-Status: Closed</span>
<span class="added">+Status: Open</span>
</div>
Hi.
Thank you for your response.
I have confirmed the version of System_Daemon module files on my
machine, but it is latest version , 0.6.9 !
I got the md5sum below.
$ find /usr/local/lib/php/System -type f | xargs md5sum
e3b1b1d61697676d0a4264de8baf29cf
/usr/local/lib/php/System/Daemon/OS/Debian.php
cbcf98a6693a16198b13f9d6f9a0303c
/usr/local/lib/php/System/Daemon/OS/Exception.php
dd90a14739a8f3540eaa59f017e0c4e3
/usr/local/lib/php/System/Daemon/OS/Linux.php
0514bfd37bedacb34aea78c9efb5304e
/usr/local/lib/php/System/Daemon/OS/RedHat.php
1a4d4ab2b01defb0f5abf8a483403330
/usr/local/lib/php/System/Daemon/OS/Ubuntu.php
971d6196f64970f82c3d85aa2d018d1e
/usr/local/lib/php/System/Daemon/OS/Windows.php
19f236f7723a4be0a38a7c8f18609c84
/usr/local/lib/php/System/Daemon/OS/BSD.php
59ec525d1c00abe6eee00a124faaa0cd
/usr/local/lib/php/System/Daemon/Options.php
d6e6d48091935a375b2159e7b12234b2
/usr/local/lib/php/System/Daemon/OS.php
4ced99054500109a304c2b011dc9ffd2
/usr/local/lib/php/System/Daemon/Exception.php
7663d1d63c6b294274c5a26e30a14fcd /usr/local/lib/php/System/Daemon.php
Previous Comments:
------------------------------------------------------------------------
[2009-02-22 22:05:09] kvz
<div id="changeset">
<span class="removed">-Status: Feedback</span>
<span class="added">+Status: Closed</span>
</div>
------------------------------------------------------------------------
[2009-02-22 22:04:29] kvz
<div id="changeset">
<span class="removed">-Assigned To:</span>
<span class="added">+Assigned To: kvz</span>
</div>
------------------------------------------------------------------------
[2009-02-22 22:04:16] kvz
<div id="changeset">
<span class="removed">-Status: Open</span>
<span class="added">+Status: Feedback</span>
</div>
Thank you for taking the time to report a problem with the package.
Unfortunately you are not using a current version of the package --
the problem might already be fixed. Please download a new
version from http://pear.php.net/packages.php
If you are able to reproduce the bug with one of the latest
versions, please change the package version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PEAR.
The most recent version of System_Daemon should give the error:
Since version 0.6.3, the pidfile needs to be in it's own subdirectory
like: /tmp/mydaemon/mydaemon.pid [l:961] in
/home/kevin/workspace/plutonia-system_daemon/System/Daemon.php on line
961
So this indicates that you're not using the latest version. Please
upgrade, place the .pid in it's own subdirectory and try again.
If it still fails reopen this issue.
------------------------------------------------------------------------
[2009-02-22 09:36:37] neta
Description:
------------
Is this a bug ? or my code is wrong?
Test script:
---------------
<?php
require_once("System/Daemon.php");
System_Daemon::setOption("appName", "mydaemon");
System_Daemon::setOption("appPidLocation", "/tmp/mydaemon.pid");
System_Daemon::setOption("logLocation", "/tmp/mydaemon.log");
System_Daemon::start(); //
?>
Expected result:
----------------
(No error occur)
Actual result:
--------------
$ php daemon.php
[Feb 22 18:33:05] info: starting mydaemon daemon, output in:
/tmp/mydaemon.log
PHP Fatal error: Uncaught System_Daemon_Exception: [Feb 22 18:33:05]
emerg: mydaemon daemon was unable to write pid file [l:959] in
/usr/local/lib/php/System/Daemon.php on line 959
#0 /usr/local/lib/php/System/Daemon.php(959): System_Daemon::log(0,
'mydaemon daemon...')
#1 /usr/local/lib/php/System/Daemon.php(457): System_Daemon::_summon()
#2 /home/watanabe/tmp/daemon.php(6): System_Daemon::start()
#3 {main}
thrown in /usr/local/lib/php/System/Daemon.php on line 701
Fatal error: Uncaught System_Daemon_Exception: [Feb 22 18:33:05]
emerg: mydaemon daemon was unable to write pid file [l:959] in
/usr/local/lib/php/System/Daemon.php on line 959
#0 /usr/local/lib/php/System/Daemon.php(959): System_Daemon::log(0,
'mydaemon daemon...')
#1 /usr/local/lib/php/System/Daemon.php(457): System_Daemon::_summon()
#2 /home/watanabe/tmp/daemon.php(6): System_Daemon::start()
#3 {main}
thrown in /usr/local/lib/php/System/Daemon.php on line 701
------------------------------------------------------------------------
--
Edit this bug report at http://pear.php.net/bugs/bug.php?id=15926&edit=1