Find the answer to your Linux question:
Results 1 to 2 of 2
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    laggy snaggy problem

    I have a problem, according to my lazy ass administrator, it keeps snagging up causing lag. so instead of fixing the problem he instructed me to enter root and run service httpd restart every 30 minutes. I was wondering if there is any way to have it automatically run every 30 minutes so i dont have to leave the remote terminal open with root logged in.
    service httpd restart - thats the command

  2. #2
    Linux Enthusiast KenJackson's Avatar
    Join Date
    Jun 2006
    Maryland, USA
    Wow! There is a problem here begging for a better solution.

    But you can do what you are asking for with a cron job, which I would implement this way. Create a text file, cron.txt, like this:
    # Time fields: minute, hour, day, month, day-of-week (0 or 7 is Sun)
    3,33   *   *   *   *   /sbin/service httpd restart
    Note that the PATH variable may not be set, so specify it.
    Then as root enter the command
    # crontab cron.txt
    That's it.
    You can use "crontab -l" to see what cronjobs are scheduled and "crontab -r" to unschedule all jobs.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts