network1 12.435.23.12 12.45.34.23 network2 32.334.23.23 54.56.563.32 #### #/usr/bin/perl use Net::Telnet; use Net::Telnet::Cisco; #Opening a input text file for logging into devices open inFile, '<', 'ip.txt' or die "MESSAGE From SAT : Couldn't open iput.txt for reading verify the correct path : $!"; print " hello \n\n "; #storing the contents of the input file to a variable print " Reading the file . . .\n\n"; while (! eof inFile) { $line .= ' ' . ; chomp $line; print $line,"\n\n"; if ($line=/.*?\w/) { $accountname = $1; print "Account name =", $accountname; open ("$accountname"), or die "Could not create the account name.txt.\n"; ................ . . } }