in reply to One liner to test existance of a file

This is a bit clumsy and not very system/maintenance friendly way of getting remote system uptime, in my opinion.
I think much better to poll via SNMP for the hrSystemUptime OID. This is reported in centiseconds for M$ systems and milliseconds for other (unix/linux/etc) systems. The relevant OID to read is .1.3.6.1.2.1.25.1.1.0
Then you would end up with a much cleaner implementation using SNMP perl module instead.
the hardest line to type correctly is: stty erase ^H
  • Comment on Re: One liner to test existance of a file