How to run test in parallel in multiple nodes?

I am not able to run php file in background on my servers. When I am running php test.php, it answers or even php test.php > anser.txt also works. However when I am running the same php file in background i.e php test.php > answer.txt &  it fails.

  • It kills the answer.txt & there is not output in the file. Please help me out to run the same. However I am using an work around method for the same i.e php test.php < /dev/null > answer.txt &. This works.

  • Answer:

    you have to run it in nohup. So in your example the command would be: nohup php test.php > answer.txt The PHP CLI works different than when it is being used by a webserver.

Nick Funnell at Quora Visit the source

Was this solution helpful to you?

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.