log format
Hi all. I'm using qmail-1.03, and it's working ok. Yesterday, I change the way to start qmail from tarball/INSTALL docs to LWQ. The problem is that the logs don't says (in human readable format), the date and time of each event. Instead of that, I see lines like @40003b535a1736077d54 tcpserver: ok 7541 0:10.1.1.1:25 :10.1.1.194::2525 How can I configure qmail startup process to log the events date and time like syslog? (Jul 17 12:03:00 host process: blah, blah, blah...) thanks --ejg
R: log format
About date, to view, pipe it to tai64nlocal. [root@homer-a main]# tail current @40003b54533929f756ec delivery 880: success: did_0+0+1/ @40003b54533929f78d9c status: local 0/60 remote 0/60 @40003b54533929f7a50c end msg 275504 @40003b545339309cfc04 new msg 275507 @40003b545339309d1b44 info msg 275507: bytes 10277 from sender qp 2219 uid 502 @40003b54533a07bdcdcc starting delivery 881: msg 275507 to local mailbox @40003b54533a07bdfcac status: local 1/60 remote 0/60 @40003b54533a0b7ec984 delivery 881: success: did_0+0+1/ @40003b54533a0b7f041c status: local 0/60 remote 0/60 @40003b54533a0b7f17a4 end msg 275507 [root@homer-a main]# tail current | tai64nlocal 2001-07-17 17:01:03.704075500 delivery 880: success: did_0+0+1/ 2001-07-17 17:01:03.704089500 status: local 0/60 remote 0/60 2001-07-17 17:01:03.704095500 end msg 275504 2001-07-17 17:01:03.815594500 new msg 275507 2001-07-17 17:01:03.815602500 info msg 275507: bytes 10277 from sender qp 2219 uid 502 2001-07-17 17:01:04.129879500 starting delivery 881: msg 275507 to local mailbox 2001-07-17 17:01:04.129891500 status: local 1/60 remote 0/60 2001-07-17 17:01:04.192858500 delivery 881: success: did_0+0+1/ 2001-07-17 17:01:04.192873500 status: local 0/60 remote 0/60 2001-07-17 17:01:04.192878500 end msg 275507 [root@homer-a main]# Hope it helps. --- Cordiali saluti / Best regards Andrea Cerrito ^^ Net.Admin @ Centro MultiMediale di Terni S.p.A. P.zzale Bosco 3A 05100 Terni IT Tel. +39 0744 5441330 Fax. +39 0744 5441372 -Messaggio originale- Da: GARGIULO Eduardo INGDESI [mailto:[EMAIL PROTECTED]] Inviato: martedì 17 luglio 2001 17.11 A: qmail list Oggetto: log format Hi all. I'm using qmail-1.03, and it's working ok. Yesterday, I change the way to start qmail from tarball/INSTALL docs to LWQ. The problem is that the logs don't says (in human readable format), the date and time of each event. Instead of that, I see lines like @40003b535a1736077d54 tcpserver: ok 7541 0:10.1.1.1:25 :10.1.1.194::2525 How can I configure qmail startup process to log the events date and time like syslog? (Jul 17 12:03:00 host process: blah, blah, blah...) thanks --ejg
Re: log format
* GARGIULO Eduardo INGDESI [EMAIL PROTECTED] Hi all. I'm using qmail-1.03, and it's working ok. Yesterday, I change the way to start qmail from tarball/INSTALL docs to LWQ. The problem is that the logs don't says (in human readable format), the date and time of each event. Instead of that, I see lines like @40003b535a1736077d54 tcpserver: ok 7541 0:10.1.1.1:25 :10.1.1.194::2525 How can I configure qmail startup process to log the events date and time like syslog? (Jul 17 12:03:00 host process: blah, blah, blah...) As others have pointed out, you should use tai64nlocal from the daemontools package to convert these timestamps. If you use GNU less for viewing logs, see http://www.orakel.ntnu.no/~kjetilod/tips/ for instructions on how to do this conversion automatically. -- Kjetil
Re: log format
* pop corn [EMAIL PROTECTED] http://www.orakel.ntnu.no/~kjetilod/tips/ Terrific tip! this is how I got it to work on Redhat 7.0: # pwd /usr/bin # diff lesspipe.sh lesspipe.sh.orig \@*.s) tai64nlocal $1 ;; # http://www.orakel.ntnu.no/~kjetilod/tips/ # export LESSOPEN=|/usr/bin/lesspipe.sh %s You should probably save your modified lesspipe.sh in ~/bin; otherwise it might be lost in an upgrade. I have added a paragraph for Red Hat users. If anyone has information about lesspipe on other platforms, email me and I'll add them. -- Kjetil
Re: log format
I've tried this several different times on my RH machine but it never worked. Checked paths, perms, etc. No luck. Well, I just got it working!! I had to remove the \@ from the \@*.s line and it works like a charm. I'm guessing it's a shell thing? - Gary Kjetil Ødegaard wrote: * pop corn [EMAIL PROTECTED] http://www.orakel.ntnu.no/~kjetilod/tips/ Terrific tip! this is how I got it to work on Redhat 7.0: # pwd /usr/bin # diff lesspipe.sh lesspipe.sh.orig \@*.s) tai64nlocal $1 ;; # http://www.orakel.ntnu.no/~kjetilod/tips/ # export LESSOPEN=|/usr/bin/lesspipe.sh %s You should probably save your modified lesspipe.sh in ~/bin; otherwise it might be lost in an upgrade. I have added a paragraph for Red Hat users. If anyone has information about lesspipe on other platforms, email me and I'll add them. -- Kjetil