The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

custom commands after weblog

Discussion in 'General Discussion' started by ramil, Jan 21, 2012.

  1. ramil

    ramil Active Member

    Joined:
    Dec 28, 2003
    Messages:
    38
    Likes Received:
    0
    Trophy Points:
    6
    Hello,

    How can I determine my own commands/scripts right after the processing of web log files by cPanel?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    As I understand, you are looking for a script hook to use after statistics processing. There are no script hooks available for this due to the nature of how statistics are processed. You can find a full list of available script hooks at:

    Script Hooks

    May I ask what specific commands you want to run, and is there a specific reason it has to occur after statistics are processed?

    Thank you.
     
  3. ramil

    ramil Active Member

    Joined:
    Dec 28, 2003
    Messages:
    38
    Likes Received:
    0
    Trophy Points:
    6
    I'm using a Nginx web server as a front-end to Apache, and every time, after web logs are processing, nginx is unable to write logs to files, and I must send a special signal to nginx worker process to reopen all log files...
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    You could configure specific times for statistics to process via:

    "WHM >> Server Configuration >> Statistics Software Configuration >> Configure Statistics Process Time Schedule"

    Then, you could add a cron job to run at specific times to execute the required commands. The use of Nginx is not supported by cPanel, thus there are no native tools available with cPanel to resolve this type of issue.

    Thank you.
     
Loading...

Share This Page