ispCP - Board - Support
Duplicate cron entries - Printable Version

+- ispCP - Board - Support (http://www.isp-control.net/forum)
+-- Forum: ispCP Omega Support Area (/forum-30.html)
+--- Forum: System Setup & Installation (/forum-32.html)
+--- Thread: Duplicate cron entries (/thread-5309.html)



Duplicate cron entries - FeG - 01-01-2009 08:12 PM

Hi all...

I'm using ispCP since RC2 and have updated it constantly with every RC, so I'm now at RC7...

Coincidentally I've seen that there are duplicate entries for some cron jobs:

/etc/cron.d/ispcp
Code:
# delayed tasks START.

# Quota
@daily root /var/www/ispcp/engine/quota/ispcp-dsk-quota &>/var/log/ispcp/ispcp-dsk-quota.log

# Traffic
0,30    *       *       *       *  root /var/www/ispcp/engine/traffic/ispcp-srv-traff &>/var/log/ispcp/ispcp-srv-traff.log
0,30    *       *       *       *  root /var/www/ispcp/engine/traffic/ispcp-vrl-traff &>/var/log/ispcp/ispcp-vrl-traff.log
15,45   *       *       *       *  root /var/www/ispcp/engine/traffic/ispcp-vrl-traff-correction &>/var/log/ispcp/ispcp-vrl-traff-correction.log

# customer logs
@daily root /var/www/ispcp/engine/tools/ispcp-httpd-logs-mngr &>/var/log/ispcp/ispcp-httpd-logs-mngr.log

# Backup
@daily root /var/www/ispcp/engine/backup/ispcp-backup-all yes &>/var/log/ispcp/ispcp-backup-all-mngr.log
@daily root /var/www/ispcp/engine/backup/ispcp-backup-ispcp noreport &>/var/log/ispcp/ispcp-backup-ispcp-mngr.log

...

crontab -l
Code:
# Quota
0               23              * * *  /var/www/ispcp/engine/quota/ispcp-dsk-quota &>/var/log/ispcp/ispcp-qsk-quota.log

# Traffic
0,30    *               * * *  /var/www/ispcp/engine/traffic/ispcp-srv-traff &>/var/log/ispcp/ispcp-srv-traff.log
0,30    *               * * *  /var/www/ispcp/engine/traffic/ispcp-vrl-traff &>/var/log/ispcp/ispcp-vrl-traff.log
15,45   *               * * *  /var/www/ispcp/engine/traffic/ispcp-vrl-traff-correction &>/var/log/ispcp/ispcp-vrl-traff-correction.log
30              23              * * *  /var/www/ispcp/engine/tools/ispcp-httpd-logs-mngr &>/var/log/ispcp/ispcp-httpd-logs-mngr.log

# Backup
0               1               * * *  /var/www/ispcp/engine/backup/ispcp-backup-all yes &>/var/log/ispcp/ispcp-backup-all-mngr.log

# AWStats
15      */6     * * *   /var/www/ispcp/engine/awstats/awstats_updateall.pl now -awstatsprog=/usr/lib/cgi-bin/awstats.pl >/dev/null 2>&1

...

I guess that the entries in root's crontab were done by one of the first ispCP versions and not deleted by later updates. Am I right?

I've also a file /etc/cron.d/ispcp.phptemp which does the same as this line in /etc/cron.d/ispcp:
Code:
0,30 *     * * *     root   /var/www/ispcp/engine/tools/ispcpphptemp.sh >/dev/null 2>&1
so I assume that ispcp.phptemp is also an old one?

Can someone confirm this?

Greetings
FeG


RE: Duplicate cron entries - sci2tech - 01-01-2009 08:50 PM

/etc/cron.d/ispcp is correct cron file. You can clear/remove rest of it


RE: Duplicate cron entries - BioALIEN - 01-03-2009 09:21 AM

@sci2tech: does this mean something went wrong somewhere in the update scripts from RC2 -> RC7?

Maybe we should wipe out cron (with a warning to user) in the next update to v1.0.0 to ensure older testers don't have any such bugs?


RE: Duplicate cron entries - FeG - 01-03-2009 10:55 PM

Hi,

(01-03-2009 09:21 AM)BioALIEN Wrote:  Maybe we should wipe out cron (with a warning to user) in the next update to v1.0.0 to ensure older testers don't have any such bugs?

this is not a critical bug since I haven't even noticed it before I looked into /etc/cron.d/ .

I don't think wiping cron is a good idea - I have some backup entries in there and would be very angry if an ispCP installation would delete them ...
Of course one could look for the ispCP-Section in crontab and remove it when calling ispcp-update, but since it only affects these users who are updating since RC2 a post in the forum should be enough..

Greetings
FeG