![]() |
Command Line - How to Tail a File?
Folks,
I'm new to Linux and I can't figure out how to tail the dmesg log. "tail dmesg" does not work. I want to do something like "tail /var/log" but I think there is no log on the N900? I installed the full GNU utilities but still unsure. Please advise |
Re: Command Line - How to Tail a File?
Busybox tail comes on the device and works fine for me.
dmesg is a binary, not a text file so you cannot tail it (well you could but you'd have to use the full path to it, and would just get garbage!). If you just want the last few lines of output that you would get from the dmesg command you could use: dmesg | tail You may also want to investigate /var/log/syslog , though I'm not sure whether the logging occurs by default or I've enabled it in the past and forgotten. As this is a "normal" file you could use: tail /var/log/syslog to see the last few lines of it. Cheers, Jan |
Re: Command Line - How to Tail a File?
and lets not forget the ever helpful tail -f for streaming a file.
|
Re: Command Line - How to Tail a File?
Quote:
|
Re: Command Line - How to Tail a File?
Quote:
|
Re: Command Line - How to Tail a File?
you'd have to run as root, but
# cat /proc/kmsg some old data... ... <6>[45179.402587] slide (GPIO 71) is now open <6>[45180.745971] slide (GPIO 71) is now closed that is the same log source from which dmesg gets its content.. |
Re: Command Line - How to Tail a File?
Thanks for your response cpitchford, that is what I was looking for!
|
All times are GMT. The time now is 19:48. |
vBulletin® Version 3.8.8