Jump to content

[SOLVED] How to check if command line php is running or not?


freephoneid

Recommended Posts

Hi,

    I've a command line PHP file, say abc.php

Now, my web application file needs to check if abc.php is running or not. How can I do that?

 

    Basically, I want to check if abc.php is running or not. How can I do it from another PHP which will be invoked through web based GUI which is using Apache?

 

Thanks!

Hi,

    I think I did not clearly mention it in the question....I want to check this through PHP program. How can I do it in PHP?? Is there any PHP command which can tell me if another PHP is running or not? btw, I'm using Linux

 

Thanks!

i think getmypid will give u process id of the current script instance that u r running, if u run the same script through another terminal, you will not get pid of that. not sure, but u can confirm.

 

just check if this is what u want.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.