in reply to system commands

The answer to your firsts question is something like :

#!/usr/bin/perl -w use strict; my @uptime = split ' ', `uptime`; print "Server rebooted in last 24 hours" if ( $uptime[2] < 1 );
The answer to your second question is simply :
print "Server rebooted in last 24 hours"

/J\

Replies are listed 'Best First'.
Re: Re: system commands
by demerphq (Chancellor) on Mar 08, 2002 at 14:19 UTC
      LOL, I`m sorry, I thought I read:
      `If you only reboot every day then Id say you have service packs to install` ...

      Which also would have made a lot of sense :))

      I need a coffee

      GreetZ!,
        ChOas

      print "profeth still\n" if /bird|devil/;
Re: Re: system commands
by Juerd (Abbot) on Mar 08, 2002 at 14:19 UTC
    ++ on the second answer :)

    44696420796F7520732F2F2F65206F
    7220756E7061636B3F202F6D736720
    6D6521203A29202D2D204A75657264