Bug#401910: munin-node: apt cron job runs even when apt plugin is not enabled
severity 401910 wishlist reassign 401910 cron merge 401910 144710 quit * David Liontooth It's not an error - it's just he command echoed, telling syslog it was run. It's perfectly orderly, I just want to silence it, as it provides no relevant information. I've installed munin-node on seven machines and get the same messages in syslog for all of them (below). The configuration on these differ a fair amount. I tried to silence it with /dev/null 21 but that didn't do the trick, so I just commented out the line. This may still just be a cron configuration issue that munin simply triggers. Ah. Yes, these messages are cron simply logging that it started the job. The fact that the job produces no output doesn't stop cron from logging that, and as far as I know there is no way to tell cron not to log for each time it invokes a job. This isn't specific to Munin, you'll see similar messages when other cron jobs are run (I see the run-parts --report /etc/cron.hourly job being logged in your excerpt, for instance). There is an open bug report in the cron package, calling for this exact functionality. If it is added I shall surely update the Munin package to make use of it, but that's impossible right now. For that reason I'm merging your bug report with this one now. You can filter out the messages from cron in /etc/syslog.conf, though. If you change the one that directs messages to /var/log/syslog to read *.*;cron,auth,authpriv.none -/var/log/syslog no cron-related messages will be logged there (which includes all the non-munin-related messages, which may or may not be acceptable to you). You can instead, optionally, direct these messages to a separate log file with a line such as cron.* /var/log/cron.log I get a lot of street cred from my colleagues when showing them munin; they somehow imagine I put all of this information together myself ;-) :-) Dec 7 08:50:01 siena /USR/SBIN/CRON[13790]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) [...] Regards -- Tore Anderson -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#401910: munin-node: apt cron job runs even when apt plugin is not enabled
* David Liontooth $ cat /etc/cron.d/munin-node # # cron-jobs for munin-node # MAILTO=root # If the APT plugin is enabled, update packages databases approx. once # an hour (12 invokations an hour, 1 in 12 chance that the update will # happen), but ensure that there will never be more than two hour (7200 # seconds) interval between updates.. */5 * * * *root if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; t$ This cronjob should not be activated if the apt / apt_all plugin is not enabled. I think you've got a corrupted installation. This line should not end with «t$», it should read: */5 * * * * root if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi Could you try replacing it with the above, or reinstalling, and see if that helps? This job should never generate any output whatsoever if the APT plugins are disabled. I like a quiet syslog and discovered the bug from getting crowds of these. It's strange that you get it in your syslog, cron is supposed to mail output to root as per the MAILTO setting (even errors resulting from your corrupted file). Weird. What is the error that ends up in your syslog, exactly? Could you please paste an example? There are clearly some residual issues with munin and cron -- cf. #301361 #353979 #332285 #382947 None of these are about the cronjob of the apt plugin, so they're not related to the problem you're describing. That said, this works beautifully out of the box, so thanks for expert packaging. Thanks. :-) -- Tore Anderson
Bug#401910: munin-node: apt cron job runs even when apt plugin is not enabled
Hi Tore, Tore Anderson wrote: * David Liontooth $ cat /etc/cron.d/munin-node # # cron-jobs for munin-node # MAILTO=root # If the APT plugin is enabled, update packages databases approx. once # an hour (12 invokations an hour, 1 in 12 chance that the update will # happen), but ensure that there will never be more than two hour (7200 # seconds) interval between updates.. */5 * * * *root if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; t$ This cronjob should not be activated if the apt / apt_all plugin is not enabled. I think you've got a corrupted installation. This line should not end with «t$», it should read: */5 * * * * root if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi Could you try replacing it with the above, or reinstalling, and see if that helps? This job should never generate any output whatsoever if the APT plugins are disabled. I pasted incorrectly; the line is correct in /etc/cron.d/munin-node. I'm glad to hear the job is not expected to generate any output. I like a quiet syslog and discovered the bug from getting crowds of these. It's strange that you get it in your syslog, cron is supposed to mail output to root as per the MAILTO setting (even errors resulting from your corrupted file). Weird. What is the error that ends up in your syslog, exactly? Could you please paste an example? It's not an error - it's just he command echoed, telling syslog it was run. It's perfectly orderly, I just want to silence it, as it provides no relevant information. I've installed munin-node on seven machines and get the same messages in syslog for all of them (below). The configuration on these differ a fair amount. I tried to silence it with /dev/null 21 but that didn't do the trick, so I just commented out the line. This may still just be a cron configuration issue that munin simply triggers. I get a lot of street cred from my colleagues when showing them munin; they somehow imagine I put all of this information together myself ;-) David Dec 7 08:50:01 siena /USR/SBIN/CRON[13790]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 08:55:01 siena /USR/SBIN/CRON[14538]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:00:01 siena /USR/SBIN/CRON[15317]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:05:01 siena /USR/SBIN/CRON[16103]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:10:01 siena /USR/SBIN/CRON[16791]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:15:01 siena /USR/SBIN/CRON[17479]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:17:01 siena /USR/SBIN/CRON[18095]: (root) CMD ( cd / run-parts --report /etc/cron.hourly) Dec 7 09:30:01 chianti /USR/SBIN/CRON[18868]: (munin) CMD (if [ -x /usr/bin/munin-cron ]; then /usr/bin/munin-cron; fi) Dec 7 09:30:01 chianti /USR/SBIN/CRON[18866]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:35:01 chianti /USR/SBIN/CRON[19563]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:35:01 chianti /USR/SBIN/CRON[19565]: (munin) CMD (if [ -x /usr/bin/munin-cron ]; then /usr/bin/munin-cron; fi) Dec 7 09:40:01 chianti /USR/SBIN/CRON[20223]: (root) CMD (if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; then /etc/munin/plugins/apt update 7200 12 /dev/null; fi) Dec 7 09:40:01 chianti /USR/SBIN/CRON[20225]: (munin) CMD (if [ -x /usr/bin/munin-cron ]; then
Bug#401910: munin-node: apt cron job runs even when apt plugin is not enabled
Package: munin-node Version: 1.2.5-1 Severity: minor From a fresh default installation: $ munin-node-configure Plugin | Used | Extra information -- | | - apt| no | apt_all| no | $ cat /etc/cron.d/munin-node # # cron-jobs for munin-node # MAILTO=root # If the APT plugin is enabled, update packages databases approx. once # an hour (12 invokations an hour, 1 in 12 chance that the update will # happen), but ensure that there will never be more than two hour (7200 # seconds) interval between updates.. */5 * * * *root if [ -x /etc/munin/plugins/apt_all ]; then /etc/munin/plugins/apt_all update 7200 12 /dev/null; elif [ -x /etc/munin/plugins/apt ]; t$ This cronjob should not be activated if the apt / apt_all plugin is not enabled. I like a quiet syslog and discovered the bug from getting crowds of these. There are clearly some residual issues with munin and cron -- cf. #301361 #353979 #332285 #382947 That said, this works beautifully out of the box, so thanks for expert packaging. Dave -- System Information: Debian Release: 4.0 APT prefers unstable APT policy: (500, 'unstable') Architecture: amd64 (x86_64) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.18 Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) Versions of packages munin-node depends on: ii adduser 3.100 Add and remove users and groups ii libnet-server-perl0.94-1 An extensible, general perl server ii lsb-base 3.1-22 Linux Standard Base 3.1 init scrip ii perl 5.8.8-6.1 Larry Wall's Practical Extraction ii procps1:3.2.7-3 /proc file system utilities Versions of packages munin-node recommends: pn libnet-snmp-perl none (no description available) -- no debconf information -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#401910: munin-node: apt cron job runs even when apt plugin is not enabled
Please close the bug -- my misunderstanding. The cron job runs, but since apt isn't enabled, it doesn't actually do anything. I've added /dev/null 21 to the end of the cronjob to silence it, which is probably a good default. Dave -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]