Advertisement
dHeinemann

uptime.pl

Apr 29th, 2011
279
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Perl 0.21 KB | None | 0 0
  1. #!/usr/bin/perl
  2. use strict;
  3. use warnings;
  4. #Prints the Windows boot time using net stats srv.
  5.  
  6. my @output =  `net stats srv`;
  7. my $uptime =  $output[3];
  8. $uptime    =~ s/Statistics since //gi;
  9. print("$uptime");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement