How to run a php or any script using nohup

Suppose you want to run a php/any file with certain time gap then you can configure it in Crontab. But as we know in crontab we can run a file minimum in 1 minute gap. But if it requires to run a file below than 1 minute gap then you have to run it through nohup. For this First crate a bash script to run the php file. Then run the bash script with nohup.

First Create a bash file:

Then execute the command to run the script with nohup:

Share and Enjoy

  • Facebook
  • Twitter
  • Delicious
  • LinkedIn
  • StumbleUpon
  • Add to favorites
  • Email
  • RSS
The following two tabs change content below.

Tapas Mishra

Sr. Engineer (DevOps)
Loves to work on Opensource products. Having experience on Linux environment. Knowledge on Public cloud services like AWS, Rackspace, DigitalOcean, Linode. Please don't hesitate to give a comment on the posts. Your comments are my strength.

Leave a Reply