---------- Forwarded message ----------
From: Raheel Hassan <raheel.has...@gmail.com>
Date: Wed, Aug 19, 2009 at 2:48 PM
Subject: This code is not giving the required output.
To: beginners-h...@perl.org


Hello,

I have problems in executing the under given code. I need to restart my
database, apache etc services using on ubuntu machine. for that i have
written thsi code, but the result of the command is not saving in the file ,
any suggestions please.


my $result = 'service mysql start 2>>/var/log/comm.log';
sleep 10;
if($result =~ /OK/)
      {
     print "OK";
         }
  else
        {
        print "NOK\n";



Regards,
Raheel.

Reply via email to