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.

cpanellogd starting time

Discussion in 'General Discussion' started by rebel7, Jul 20, 2015.

  1. rebel7

    rebel7 Registered

    Joined:
    Jul 20, 2015
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    ok
    cPanel Access Level:
    Root Administrator
    As far as I can tell, the only setting that affects the timing of when cpanellogd performs raw access log rotation is BLACKHOURS. Is there something that sets the start time that I'm not finding? I have a few dozen virtual domains and I thought if I turned stats off that the logs would rotate earlier but it finishes at 7:05 AM every day and within minutes on all domains whether stats is enabled or not. I want it to run just after midnight everyday. Setting the blackhours, leaving a window between midnight and 3:00 AM causes it to not run at all?

    The hosting company went through a week and 8 techs and couldn't find any other settings (nor could I). They recommend disabling cpanellogd and utilizing logrotate, which I'm inclined to do if nothing else, but I can't believe that there isn't a cron job somewhere that is controlling the starting time for this that we're just missing?

    Help appreciated.
     
  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 :)

    That is in-fact the supported method of ensuring statistics only generate at a specific time. You can browse to "WHM Home » Server Configuration » Statistics Software Configuration" and change the "Log Processing Frequency" to a value such as "3 hours" if you want to ensure statistics run on the first night. Otherwise, are you sure at least 24 hours had passed since the last statistics generation when you first made the change to the black out hours?

    Thank you.
     
  3. rebel7

    rebel7 Registered

    Joined:
    Jul 20, 2015
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    ok
    cPanel Access Level:
    Root Administrator
    Michael,

    My apologies for not replying. I've been quite busy on a project and "assumed" that I would get an email notification if a reply came through and have only now taken time to loop back to have a look.

    As a test, I allowed 2 days to pass with all stats disabled and with that 3 hour window available for the log rotation. With/without stats enabled the log rotation occurs at the same exact time, around 7:00 AM, each day. This screams to me that there is a cron job somewhere triggering this that either I haven't found or I'm missing how the cron job is triggering the log rotation. I've put a few hours into it and have researched for it and just haven't had time to pursue it further.

    I thought I would drop a post on the cpanel forum and someone more familiar with cpanel would just say, "Oh yeah, the cpanellogd is triggered by such-n-such, etc., and you can change the timing here, etc". Since I don't need stats/bandwidth reporting I am inclined to disable cpanellogd, which is what the host tech support suggests as well, and set up logrotate to handle the domolgs rotation. I am reluctant to disable something that I am not intimately familiar with but it appears that there would be no ill effect in doing so since I don't need stats/bandwidth. This is another thing I would like input on from this forum.

    Thank you. (and I promise to check back frequently for a response ;-} )
     
  4. rebel7

    rebel7 Registered

    Joined:
    Jul 20, 2015
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    ok
    cPanel Access Level:
    Root Administrator
    *bumping* this for hope of more input? Does no one know what sets the start time for cpanellogd?
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    There's no specific cron job that determines when cpanellogd processes statistics, but rather cpanelogd is a process that's always running. You could setup your own custom cron job that utilizes the "/scripts/runstatsonce" command if you want to process statistics at a specific time.

    Thank you.
     
Loading...

Share This Page