Logging information through printk

Frank Ch. Eigler fche@redhat.com
Mon Jun 4 17:38:00 GMT 2007


Alex Iribarren <alex.iribarren.lists@gmail.com> writes:

> I want to get the output into the system log, and it seemed like the
> best way. Now I'm experimenting with printf, staprun -o and staprun >>
> /var/bla, but I'm not totally pleased with it. 

Appending to a file also written to by syslogd is a bit ugly.  You can
just pipe to logger(1) for relaying to your local syslogd:

stap netlog.stp | logger

> For one, I loose the nice looking timestamps. :(

# stap -e 'probe begin { log (ctime(gettimeofday_s())) exit() }'
Mon Jun  4 17:34:04 2007

- FChE



More information about the Systemtap mailing list