1 2:50 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: [Perl-unix-users] Script Help Please
Steve,
I made the correction as follows:
if (/\bUP\b/ && /$server_name/) Does not work.
I also tried:
if (/$server_name/) Does not work.
And:
if (/\b$server_name
Steve,
I made the correction as follows:
if (/\bUP\b/ && /$server_name/) Does not work.
I also tried:
if (/$server_name/) Does not work.
And:
if (/\b$server_name\b/) Does not work.
I have checked that the variable $server_name is defined but it seems like the compare
is not working.
Here
Try
if (/\bUP\b/ && /$server_name/)
You are not matching on $server_name as $server_name is not enclosed by the
match operator. You could easily put this in a single regular expression if
the position of $server_name is predictable. e.g. It alway falls after UP.
If you cannot predict where the