[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Monitoring /dev/log?
From: |
Martin Pala |
Subject: |
Re: Monitoring /dev/log? |
Date: |
Mon, 18 Jul 2011 16:44:41 +0200 |
The STREAM socket is still tried ... you need to add the mentioned "type udp"
option to the "if failed unixsocket ..." test and reload monit to reflect the
new configuration:
monit reload
Regards,
Martin
On Jul 18, 2011, at 3:59 PM, mad wrote:
> Am 18.07.2011 15:23, schrieb Aleksandrov Artyom:
>> Hi, I wrote about same problem with syslog-ng
>> http://lists.nongnu.org/archive/html/monit-dev/2011-06/msg00026.html
>> It not works for me, if I use
>> if failed unixsocket /dev/log type udp then restart
>
> I have the same problem. I now use the line with 'udp' and strace shows
> a stream connection.
>
> gettimeofday({1310997069, 22086}, NULL) = 0
> socket(PF_FILE, SOCK_STREAM, 0) = 5
> fcntl64(5, F_GETFL) = 0x2 (flags O_RDWR)
> fcntl64(5, F_SETFL, O_RDWR|O_NONBLOCK) = 0
> connect(5, {sa_family=AF_FILE, path="/dev/log"}, 110) = -1 EPROTOTYPE
> (Protocol wrong type for socket)
> shutdown(5, 2 /* send and receive */) = 0
> close(5) = 0
>
> BTW, monit is configured to use syslog. There it connects correctly. ;-)
>
> socket(PF_FILE, SOCK_DGRAM|SOCK_CLOEXEC, 0) = 3
> connect(3, {sa_family=AF_FILE, path="/dev/log"}, 110) = 0
> send(3, "<14>Jul 18 13:51:08 monit[28975]"..., 74, MSG_NOSIGNAL) = 74
>
> Regards,
> mad
>