Re: what's your most favourite feature of perl?

2006-12-26 Thread Mazhar
In my case Regular expressions and the working with file (whether read or right) is the best in Perl. Infact the reading and writing of contents to a file no matter how big it is will happen very fast. Thanks Mazhar On 12/26/06, Arthur Vanderbilt <[EMAIL PROTECTED]> wrote: R

Re: Grep through a log file

2006-11-09 Thread Mazhar
[A-Z,a-z]/[d,o]/ ; print $string ;} Please help me - Sponsored Link Mortgage rates near historic lows: $150,000 loan as low as $579/mo. Intro-*Terms Hi, U can try with the below $string=~s/([A-Z])/d$1/ ; $string=~s/([a-z])/o$1; Regards Mazhar

Re: how to print "\n" in the output file

2006-11-04 Thread Mazhar
nt "\n" ; Any Suggestions?? thanks, Mihir Hi, U can keep the \n into a hash table (value) and can access the same using its key Regards Mazhar

Re: Perl Script as a Cron Job

2006-10-19 Thread Mazhar
On 10/12/06, Paul <[EMAIL PROTECTED]> wrote: On Wed, October 11, 2006 7:03 am, Mazhar wrote: > Dear All, > > My Code is to ping a range of IP reading from a text file and if they are > not reachable then just write the IP's to a file. Regarding permissions i > am run

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
.out 2>&1 -- Hi Jason Can u help me in providing the path where the cron jobs write to a log, as i can debug more seeing the same in the log file Regards Mazhar *From:* Mazhar [mailto:[EMAIL PROTECTED] *Sent:* Wednesday, October 11, 2006 11:05 AM *T

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
On 10/11/06, Beginner <[EMAIL PROTECTED]> wrote: On 11 Oct 2006 at 17:14, Mazhar wrote:> From the help above i created a new perl code and i was successfull in > running the code by typing the command /scripts/newxxx.pl but the same is> not executed by cron i have the cron entry

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
On 10/11/06, Ken Foskey <[EMAIL PROTECTED]> wrote: On Wed, 2006-10-11 at 16:45 +0400, Mazhar wrote: > I have created the file in Windows and have pasted the entries in HP-UNIX (i > mean copied). I cannot find the command dos2unix in HP UX. > easy check, change command line t

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
On 10/11/06, Paul Johnson <[EMAIL PROTECTED]> wrote: On Wed, Oct 11, 2006 at 04:18:04PM +0400, Mazhar wrote: > >On Wed, Oct 11, 2006 at 03:35:03PM +0400, Mazhar wrote: > > > >> 1. If i run the code /scripts/xxx.pl i get the below error... > >> > >

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
On 10/11/06, Paul Johnson <[EMAIL PROTECTED]> wrote: On Wed, Oct 11, 2006 at 03:35:03PM +0400, Mazhar wrote: > 1. If i run the code /scripts/xxx.pl i get the below error... > > >>>interpreter "/usr/bin/perl" not found > sh: /scripts/xxx.pl: not fo

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
Dear Thomas, I am running PING from the package Net, can u tell me where can i find the logs of cron jobs as because with that i will be able to check the possibility of not running the script, please Regards Mazhar On 10/11/06, Thomas Bätzler <[EMAIL PROTECTED]> wrote: Mazhar &

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
I did not get the meaning of (Quote properly) Regards Mazhar On 10/11/06, Bjørge Solli <[EMAIL PROTECTED]> wrote: This is the last top-posted email from you that I will answer.. Please learn how to quote properly! On Wednesday 11 October 2006 13:14, Mazhar wrote: > 1. Is /scripts/xx

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
$line; my @host_array; `rm pingnotif*.*`; `touch alive.log`; _- Regards Mazhar On 10/11/06, Steve Finkelstein <[EMAIL PROTECTED]> wrote: What #3 means, is your shebang should contain the full path to perl. This could be some

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
indicate the full path to the perl binary? Can u explain me what does the above signify Regards Mazhar On 10/11/06, Owen Cook <[EMAIL PROTECTED]> wrote: On Wed, Oct 11, 2006 at 03:03:12PM +0400, Mazhar wrote: > Dear All, > > My Code is to ping a range of IP reading from a t

Re: Perl Script as a Cron Job

2006-10-11 Thread Mazhar
cron like one below, 10 * * * * /scripts/.pl Can u all please help on the above Regards Mazhar On 10/9/06, Paul Johnson <[EMAIL PROTECTED]> wrote: On Mon, Oct 09, 2006 at 03:23:49PM +0400, Mazhar wrote: > I tried with the below and made my script as executable with chmod command

Re: Perl Script as a Cron Job

2006-10-09 Thread Mazhar
I tried with the below and made my script as executable with chmod command but the same is not running every 10 minutes. Need your help Regards Mazhar On 10/9/06, Hal Wigoda <[EMAIL PROTECTED]> wrote: get rid of the /. On Oct 9, 2006, at 5:55 AM, Mazhar wrote: > When i add the

Re: Perl Script as a Cron Job

2006-10-09 Thread Mazhar
When i add the entry as specified i get the below error (i.e) */10 * * * * /scritps/xxx.pl in cron *crontab: error on previous line; unexpected character found in line.* Regards Mazhar On 10/9/06, Jeff Pang <[EMAIL PROTECTED]> wrote: > >I have prepared a script that is to be r

Perl Script as a Cron Job

2006-10-09 Thread Mazhar
Regards Mazhar

Re: Help on chomp()

2006-08-22 Thread Mazhar
On 8/22/06, John W. Krahn <[EMAIL PROTECTED]> wrote: Mazhar wrote: > Dear Frndz, Hello, > I am writing the below code and i am facing a problem in chomp (its an > HP UX Box) > > Code > > #!/usr/bin/perl > >

Help on chomp()

2006-08-21 Thread Mazhar
02 From the output i see the first character is missing in the output.. Thanks Mazhar

Re: Script Required to Check a range of IP's

2006-06-29 Thread Mazhar
Thanks Prabhu, Your script works Regards Mazhar On 6/29/06, Prabu <[EMAIL PROTECTED]> wrote: Hello, Hope this is what you need Input File --- test.txt 172.16.1.194 172.16.1.20 172.16.1.200 172.16.1.34 Program to check active or not -- pingpro.pl #!/usr/bin/perl use stric

Re: Script Required to Check a range of IP's

2006-06-29 Thread Mazhar
On 6/29/06, Ryan Frantz <[EMAIL PROTECTED]> wrote: > -Original Message- > From: Mazhar [mailto:[EMAIL PROTECTED] > Sent: Thursday, June 29, 2006 11:44 AM > To: Perl Beginners > Subject: Script Required to Check a range of IP's > > Hi Folks, > Howdy,

Re: Script Required to Check a range of IP's

2006-06-29 Thread Mazhar
thanks Joshua for the help but the server is very critical and they will not install any external softwares. This is the policy and i have to adhere to the policy... i need a perl script to do so.. Regards Mazhar On 6/29/06, Joshua Colson <[EMAIL PROTECTED]> wrote: On Thu, 2006-06-29

Script Required to Check a range of IP's

2006-06-29 Thread Mazhar
ost_array) { print "$host is "; print "NOT " unless $p->ping($host, 2); print "reachable.\n"; sleep(1); } $p->close(); close (FILE); ####### Needs your help on the above Regards Mazhar

Re: Help Required on the Below Script

2006-06-14 Thread Mazhar
Thanks everybody for the support.. it is working fine.. Regards Mazhar On 6/14/06, John W. Krahn <[EMAIL PROTECTED]> wrote: Mazhar wrote: > Hello, Hello, > I am writing perl on windows installing Activestate Perl and the code is > reading a text file and processing it, >

Help Required on the Below Script

2006-06-14 Thread Mazhar
11 00:00:02 (7):(5852) tc1a-pgw-1m, Waiting for another gather on REPORTER_GATHER_MUTEX_FOR_TC1A_PGW_1M 2006/06/11 00:00:02 (7):(4492) tc1a-pgw-1m, Waiting for another gather on REPORTER_GATHER_MUTEX_FOR_TC1A_PGW_1M Please help me out on the above as i am not able to understand the error output.. Regards Mazhar

Re: Help in checking the OS type...

2006-04-26 Thread Mazhar
Dear Balan Yes Man Checking the OS type i.e. whether linux or windows. and then checking the drives or volumes present and calculate the disk space. regards Mazhar On 4/25/06, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > Did you mean kind of operating system like windo

Help required on the script

2006-04-25 Thread Mazhar
e Column name)(.*)/ ) (This Unique Column Name will be present in the second position Seperated by a Space Delimet) { } } ## How can i check the existence of Unique set at the 2nd Position. Thanks in Advance regards Mazhar

Re: perl help

2006-04-25 Thread Mazhar
talled on a unix flavor machine. man perl man perlre man perlvar etc.. ALL THE BEST!!! Regards Mazhar

Re: Help in checking the OS type...

2006-04-25 Thread Mazhar
On 4/25/06, Jay Savage <[EMAIL PROTECTED]> wrote: > > *Don't top post.* > > On 4/25/06, Mazhar <[EMAIL PROTECTED]> wrote: > > Paul, > > > > It lists me out the operating system name thanks for the same. How can i > go > > about

Re: Help in checking the OS type...

2006-04-25 Thread Mazhar
Paul, It lists me out the operating system name thanks for the same. How can i go about getting the different drives/volumes created on the same... Regards Mazhar On 4/25/06, Paul D. Kraus <[EMAIL PROTECTED]> wrote: > > > > On 4/25/06, Mazhar <[EMAIL PROTECTED]>

Help in checking the OS type...

2006-04-25 Thread Mazhar
Hi Folks, I need to develop a script where in i need to first check the type of OS and then go about in finding the drives. I need your help in getting an idea of how to start about this... Thanks in Advance Regards Mazhar

Re: Split function help

2006-04-25 Thread Mazhar
Dear Irfan, i think for the code you can try the below, ($some_thing1,$some_thing2,$something_3)=split($test,".") Regards Mazhar On 4/25/06, Tom Allison <[EMAIL PROTECTED]> wrote: > > Irfan J Sayed wrote: > > Hi, > > > > I have a following

Re: Running Perl Code in Windows

2006-04-24 Thread Mazhar
Thanks Yuvraj itz working Regards Mazhar On 4/24/06, santhosh Yuvaraj <[EMAIL PROTECTED]> wrote: > > Hai, > > Your problem is because of using the wrong perl2exe version > > You should download the version with respect to your perl version. > > I thnk your perl ver

Re: Running Perl Code in Windows

2006-04-24 Thread Mazhar
x.pl' to x.exe ERROR: Can't open C:\Perl Execute\p2x560.dll -- Your help is required in the above case. Regards Mazhar On 4/24/06, John Ackley <[EMAIL PROTECTED]>

Running Perl Code in Windows

2006-04-23 Thread Mazhar
. Thanks all in Advance.. Regards Mazhar

Re: Help Required on the Script

2006-04-06 Thread Mazhar
thanks Raymond for the help it works, and what do u mean by variable interpolation Regards Mazhar On 4/6/06, Raymond Raj <[EMAIL PROTECTED]> wrote: > > > -Original Message- > > From: Mazhar [mailto:[EMAIL PROTECTED] > > Sent: Thursday, April 06, 2006 2:41 PM &

Re: Help Required on the Script

2006-04-06 Thread Mazhar
bove i get the below error... In string, @04 now must be written as [EMAIL PROTECTED] at regular.pl line 5, near " [EMAIL PROTECTED]" Execution of regular.pl aborted due to compilation errors. Your help is required

Re: Help Required on the Script

2006-04-05 Thread Mazhar
thanks Jamie. It is Working. Regards Mazhar On 4/5/06, Jaime Murillo <[EMAIL PROTECTED]> wrote: > > On Tuesday 04 April 2006 23:46, Mazhar wrote: > > Hi Guyz, > > Hi Mazhar, > > > i am writin a script to automate the command snmpwalk by > > r

Help Required on the Script

2006-04-04 Thread Mazhar
print the value in the variable $tempRNA i am getting the value printed only RNAxx.xxx.xxx..txt Please help me out and Thanks is Advance Regards Mazhar

Re: extracting information from a file

2006-02-03 Thread Mazhar
Hi Rana, if the data what you need is something xxxzzz>f then you can take the entry before > by the following code $x=xxxzzz>f ($data_required,$data_notrequired)=split($x,">"). Hope the above will solve the problem. Cheers Mazhar

Re: Simple RegEx expresion

2006-01-26 Thread Mazhar
lt [regexp (_)(.*) $x match]; puts $match; Regards Mazhar On 1/25/06, John Doe <[EMAIL PROTECTED]> wrote: > > George Homorozeanu am Mittwoch, 25. Januar 2006 16.12: > > I need it with RegEx, that's my proble

Net::SSH::W32Perl

2006-01-26 Thread Mazhar
t.pl line 5. BEGIN failed--compilation aborted at sshtest.pl line 5. --- Thanks in Advance Regards Mazhar

Re: Array problem

2006-01-22 Thread Mazhar
Mr Andrej, I think the following code will work for u, open INPUT,"<$ARGV[0]"; while (){ @array=$_; } foreach $i(@array){ print $i; } Regards Mazhar On 1/23/06, Thomas Bätzler <[EMAIL PROTECTED]> wrote: > > Andrej Kastrin <[EMAIL PROTECTED]> asked: > &

Re: Problem while connecting with Mysql

2005-12-26 Thread Mazhar
enter the password) $dbh = DBI->connect("DBI:mysql:database=pix;host=$mysql_db_host;port=$mysql_db_port",$mysql_db_user,$mysql_db_pass) or die "Couldn't connect to database: $DBI::errstr\n"; Try the above Regards Mazhar On 12/27/05, Rakesh Mishra <[EMA

Help required about NET::TELNET

2005-12-05 Thread Mazhar
- The Output of the above program is pattern match read eof at prog.pl line 12 Please help me out folks as where may be the problem Regards Mazhar

Re: installing DBD::mysql

2005-12-05 Thread Mazhar
I think the MYSQL service is not running on your system, Just execute the below commands service mysqld restart I think this might solve your problem Regards Mazhar On 12/4/05, John Doe <[EMAIL PROTECTED]> wrote: > > Octavian Rasnita am Samstag, 3. Dezember 2005 19.50: > >

Re: Matching a Scalar Variable

2005-11-29 Thread Mazhar
ot;; } } } Please Help me out regards Mazhar On 11/29/05, Muthukumar <[EMAIL PROTECTED]> wrote: > > Can you post your exact work around on this to help you! Post script and > files and your requirement. > > Regards, > -Muthu > > > On 11/29

Re: Matching a Scalar Variable

2005-11-29 Thread Mazhar
Thank You Every Body for the Help i am able to check the same. regards mazhar On 11/29/05, Muthukumar <[EMAIL PROTECTED]> wrote: > > > > On 11/29/05, Mazhar <[EMAIL PROTECTED]> wrote: > > > > Sorry i am passing the OPEN as > > Open (FILE1," >

Re: Matching a Scalar Variable

2005-11-28 Thread Mazhar
Sorry i am passing the OPEN as Open (FILE1," wrote: > > > > On 11/29/05, Mazhar <[EMAIL PROTECTED]> wrote: > > > > Hi Folks, > > I have a requirement where in i have to read a file and then > > store > > the line by line items in

Matching a Scalar Variable

2005-11-28 Thread Mazhar
le but it is not searching) { print "Got the String"; } } } Please reply to me at the earliest Regads mazhar

HTTP Posting in Perl

2005-11-25 Thread Mazhar
Dear Folks, I have a requirement where in i have to post a message to a Mail Server with all the subject, To address everything. But the message sent should be posted on port 80. Please suggest me something so that i can work it out Regards Mazhar

Re: Checking the Machine's Operating System

2005-11-25 Thread Mazhar
Then how well can i write the script to log to a remote server and then > capture the following thing > 1. to know the operating system of the logged remote server > 2. to know the free space and then the number of drives or partitiones > created in the remote server > > Mazhar

Checking the Machine's Operating System

2005-11-21 Thread Mazhar
find the size of the disks partitioned. Waiting for your help at the earliest Thanks in Advance Mazhar

Need a help on this Script

2005-10-20 Thread Mazhar
|10.20.1.2 | inside | 10.20.1.199 <http://10.20.1.199> | 1282 | outside | 198.41.0.4 <http://198.41.0.4> | 53 | 846 ------ 2005-10-20 10:52:30|10.20.1.2 | inside | 10.1.3.0 <http://10.1.3.0> | | outside | 216.136.173.161 <http://216.136.173.161> | | 107 -- 2005-10-20 10:52:30|10.20.1.2 | inside | 10.6.1.220 <http://10.6.1.220> | | outside | 204.71.200.34 <http://204.71.200.34> | | 105 -- 2005-10-20 10:52:34|10.20.1.2 | inside | 10.1.3.0 <http://10.1.3.0> | | outside | 216.136.173.162 <http://216.136.173.162> | | 102 -- cat "/u01/pixscritps/mail.txt" | mail -s Thank in Advance Regards Mazhar Wipro

Sending HTML file as mail from mail command (mail -s )

2005-10-13 Thread Mazhar
s "Subject" set of users This above is working fine i need help for sending the same textfile as a HTML file as the body of the mail please help me. Thanx in Advance Regards Mazhar -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] &l