Community Forums
Connect with us on LinkedIn
  
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Aug 2004
    Posts
    294
    cPanel/Enkompass Access Level

    Root Administrator

    Default cronjob

    Im not too familiar with cron jobs so could someone tell me what id need to put if i wanted :

    /scripts/updatemysqlquota

    to run at midnight everyday?

    Also, where would i add this cronjob? surely adding it via cpanel wouldnt have the correct permissions for this?

    As i said im not too familiar with cronjobs so any help is greatly appreciated.

    thanks.

  2. #2
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    You'd have to add this as root from the shell prompt via SSH. You need the command:

    crontab -e

    That should put you into the pico editor. Then add the following line at the top:

    0 0 * * * /scripts/updatemysqlquota

    Then exit by hitting ctrl-x and then enter. That should now run that script daily at midnight for you.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  3. #3
    Member
    Join Date
    Nov 2003
    Posts
    521

    Default

    What would be the purpose of having /scripts/updatemysqlquota run nightly?..Just curious.

Similar Threads & Tags
Similar threads

  1. Cronjob
    By reporter in forum New User Questions
    Replies: 6
    Last Post: 09-01-2009, 07:03 AM
  2. Root Cronjob
    By cyclone in forum cPanel and WHM Discussions
    Replies: 6
    Last Post: 04-12-2007, 11:19 AM
  3. cronjob question
    By yosiv24 in forum New User Questions
    Replies: 1
    Last Post: 01-22-2007, 04:33 PM
  4. bad cronjob
    By Secret Agent in forum cPanel and WHM Discussions
    Replies: 17
    Last Post: 10-13-2004, 01:28 AM
  5. anyone know what this cronjob is?
    By DWHS.net in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 08-11-2004, 10:18 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube