Mailing List Archive

tailing logs
Ok this one has been driving me nuts for a while... Is there a way to tail
a log file from the cli? Right now it seems like you either have to drop
to a shell to use tail, or jump to the end in more if you don't want to
do a "-f".

--
Richard A Steenbergen <ras@e-gerbil.net> http://www.e-gerbil.net/ras
GPG Key ID: 0xF8B12CBC (7535 7F59 8204 ED1F CC1C 53AF 4C41 5ECA F8B1 2CBC)
tailing logs [ In reply to ]
Saturday, December 20, 2003, 7:31:34 PM, you wrote:
> Ok this one has been driving me nuts for a while... Is there a way to tail
> a log file from the cli? Right now it seems like you either have to drop
> to a shell to use tail, or jump to the end in more if you don't want to
> do a "-f".

show log messages
then use
CRTL+G
tailing logs [ In reply to ]
On Dec 20, 2003, at 6:31 PM, Richard A Steenbergen wrote:

> Ok this one has been driving me nuts for a while... Is there a way to
> tail
> a log file from the cli? Right now it seems like you either have to
> drop
> to a shell to use tail, or jump to the end in more if you don't want to
> do a "-f".
>

does 'monitor start <logfile>' not meet your needs?
tailing logs [ In reply to ]
Not exactly but close:

lab@R100> show log messages | ?
Possible completions:
count Count occurrences
display Display additional information
except Show only text that does not match a pattern
find Search for the first occurrence of a pattern
hold Hold text without exiting the --More-- prompt
last Display the last screen of lines in the output
match Show only text that matches a pattern
no-more Don't paginate output
request Make system-level requests
resolve Resolve IP addresses
save Save output text to a file
trim Trim specified number of columns from start of line
lab@R100> show log messages | last
Dec 3 14:00:00 M20 newsyslog[713]: logfile turned over
Dec 3 14:00:47 M20 mgd[710]: UI_COMMIT: user 'root' performed 'commit'
Dec 3 14:01:31 R100 mgd[710]: UI_COMMIT: user 'root' performed 'commit'
Dec 3 14:01:34 R100 dcd[561]: 'include "/var/etc/dcd.vrrp.conf"'
Dec 3 14:01:34 R100 dcd[561]: 'include "/var/etc/dcd.irsd.conf"'
Dec 3 14:01:34 R100 dcd[561]: couldn't open include file
'/var/etc/dcd.irsd.conf'
Dec 3 14:01:44 R100 /kernel: fxp0: link media UP 100Mb / full-duplex
Dec 3 14:02:09 R100 mgd[710]: UI_LOAD_EVENT: user 'root' is performing a
'load override'
Dec 3 14:02:18 R100 mgd[710]: UI_COMMIT: user 'root' performed 'commit'

lab@R100>

Thanks
Sean

On Sat, 20 Dec 2003, Christopher Morrow wrote:

>
> On Dec 20, 2003, at 6:31 PM, Richard A Steenbergen wrote:
>
> > Ok this one has been driving me nuts for a while... Is there a way to
> > tail
> > a log file from the cli? Right now it seems like you either have to
> > drop
> > to a shell to use tail, or jump to the end in more if you don't want to
> > do a "-f".
> >
>
> does 'monitor start <logfile>' not meet your needs?
>
> _______________________________________________
> juniper-nsp mailing list juniper-nsp@puck.nether.net
> http://puck.nether.net/mailman/listinfo/juniper-nsp
>
tailing logs [ In reply to ]
On Sat, Dec 20, 2003 at 07:28:14PM +0000, Christopher Morrow wrote:
>
> On Dec 20, 2003, at 6:31 PM, Richard A Steenbergen wrote:
>
> >Ok this one has been driving me nuts for a while... Is there a way to
> >tail
> >a log file from the cli? Right now it seems like you either have to
> >drop
> >to a shell to use tail, or jump to the end in more if you don't want to
> >do a "-f".
> >
>
> does 'monitor start <logfile>' not meet your needs?

Duh. Don't mind me, I'm a retard. For some reason I keep expecting there
to be something under show log, or even an option to fgets() try and
display data in reverse to match other formats. I actually knew about
monitor start, I just couldn't remember it, and couldn't find it again
when looking.

--
Richard A Steenbergen <ras@e-gerbil.net> http://www.e-gerbil.net/ras
GPG Key ID: 0xF8B12CBC (7535 7F59 8204 ED1F CC1C 53AF 4C41 5ECA F8B1 2CBC)