Gentoo Archives: gentoo-user

From: Alan McKinnon <alan.mckinnon@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Disable fcron logging
Date: Sat, 21 Aug 2010 13:46:31
Message-Id: 201008211543.05942.alan.mckinnon@gmail.com
In Reply to: [gentoo-user] Disable fcron logging by Alex Schuster
1 Apparently, though unproven, at 15:25 on Saturday 21 August 2010, Alex
2 Schuster did opine thusly:
3
4 > Hi there!
5 >
6 > I want to monitor the power status of my hard drives, so I wrote a little
7 > script that gives me this output:
8 >
9 > sda: standby
10 > sdb: standby
11 > sdc: active/idle 32°C
12 > sdd: active/idle 37°C
13 >
14 > This script is called every minute via an fcron entry, output goes into a
15 > log file, and I use the file monitor plasmoid to watch this log file in
16 > KDE.
17 >
18 > It's working fine, but also monitor my syslog in another file monitor
19 > plamoid, and now I get lots of these entries:
20 >
21 > Aug 21 14:21:06 [fcron] pam_unix(fcron:session): session opened for user
22 > root by (uid=0) Aug 21 14:21:06 [fcron] Job /usr/local/sbin/hdstate >>
23 > /var/log/hdstate started for user root (pid 24483) Aug 21 14:21:08 [fcron]
24 > Job /usr/local/sbin/hdstate >> /var/log/hdstate completed Aug 21 14:21:08
25 > [fcron] pam_unix(fcron:session): session closed for user root
26 >
27 > There is a nolog option for fcrontab, but I still get this output every
28 > minute:
29
30 That will tell fcron not to log stuff.
31 It will not tell other apps to not stuff
32
33 > Aug 21 15:10:06 [fcron] pam_unix(fcron:session): session opened for user
34 > root by (uid=0) Aug 21 15:10:08 [fcron] pam_unix(fcron:session): session
35 > closed for user root
36 >
37 > Hmmm... could it be that these entries do not come from fcron itself, but
38 > from PAM?
39
40 Yes.
41
42 Configure your syslogger to devnull these specific entries.
43 All three common sysloggers (syslogd,syslog-ng,rsyslog) all come with
44 extensive documentation on how to do this.
45
46
47
48 --
49 alan dot mckinnon at gmail dot com

Replies

Subject Author
Re: [gentoo-user] Disable fcron logging Alex Schuster <wonko@×××××××××.org>