Gentoo Archives: gentoo-user

From: Mick <michaelkintzios@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Daemons log on Gentoo
Date: Sun, 04 Jun 2006 11:46:59
Message-Id: 358eca8f0606040431k582c6c50td4b2b07ae0d186fb@mail.gmail.com
In Reply to: Re: [gentoo-user] Daemons log on Gentoo by Leandro Melo de Sales
1 On 03/06/06, Leandro Melo de Sales <leandroal@×××××.com> wrote:
2 > I'm using syslog-ng
3 >
4 > 2006/6/3, Daniel da Veiga <danieldaveiga@×××××.com>:
5 > > On 6/3/06, Leandro Melo de Sales <leandroal@×××××.com> wrote:
6 > > > Hi,
7 > > >
8 > > > I can't find /var/log/daemon... Every time a service is stopped or
9
10 I have this in my /var/log/ directory:
11 ==============================
12 -rw-r----- 1 root root 116223 Jun 3 18:08 daemon.log
13 ==============================
14
15 In addition, check the extract from my /etc/syslog-ng/syslog-ng.conf
16 (which created the daemon.log file in the first place):
17 ==============================
18 options {
19 chain_hostnames(off);
20 sync(0);
21
22 perm(0640);
23 dir_perm(0750);
24 create_dirs(yes);
25
26 [snip . . . ]
27 stats(43200);
28 };
29
30 source src { unix-stream("/dev/log"); internal(); pipe("/proc/kmsg"); };
31 source kernsrc { pipe("/proc/kmsg"); };
32
33 [snip . . . ]
34 destination daemon { file("/var/log/daemon.log"); };
35
36 [snip . . . ]
37 #create filters
38 filter f_daemon { facility(daemon); };
39
40 [snip . . . ]
41 #connect filter and destination
42 log { source(src); filter(f_daemon); destination(daemon); };
43 ==============================
44
45 Adding this in /etc/logrotate.conf ensures that the
46 /var/log/daemon.log file size does not get out of hand:
47 ==============================
48 # when /var/log/daemon.log gets big
49 /var/log/daemon.log
50 {
51 rotate 1
52 weekly
53 size=1M
54 }
55 ==============================
56
57 Of course the latter is only relevant if you are using logrotate.
58
59 HTH.
60 --
61 Regards,
62 Mick
63 --
64 gentoo-user@g.o mailing list

Replies

Subject Author
Re: [gentoo-user] Daemons log on Gentoo Leandro Melo de Sales <leandroal@×××××.com>