GroupStudy.com GroupStudy.com - A virtual community of network engineers
 Home  BookStore  StudyNotes  Links  Archives  StudyRooms  HelpWanted  Discounts  Login
Re: unix like command in windows DOS tail -f posted 04/25/2008
[Chronological Index] [Thread Index] [Top] [Date Prev][Date Next] [Thread Prev][Thread Next]


The resource kit has a tail (and a head) binary, or you could install
Cygwin and have all the normal *nix binaries your used to. Or you could do
something like this in python:

#!/usr/bin/python

import sys

if len(sys.argv) != 3:
        print 'Usage: ./pyTail.py <filename> <# of lines>\n'
        sys.exit(1)

fname = sys.argv[1]
nline = int(sys.argv[2])

fd = file(fname, 'r')
for line in fd.readlines()[-nline:]:
        print line,



> Guys,
> Does anyone know what is equivelent command in windows for viewing logs on
> real time?
>
> In Linux/Unix, I use
>
> # tail -f /var/log/message.log
>
> I want to read the message.log or message.txt file in windows DOS.
>
> PS: it's bloody Cisco's call manager's TRACE files, I have to open
> everytime
> to see whats happening.
>
> Frog
>
>
> Pass the CCIE in six weeks, Guaranteed!
> http://www.certscience.com/CCIE
> _______________________________________________________________________
> Subscription information may be found at:
> http://www.groupstudy.com/list/CCIELab.html