splatohara has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl -w use strict; use Net::Telnet; my $username = "admin"; my $password = 'admin1'; my $hostname = 'server.com'; my $t ; sleep 1; $t = Net::Telnet->new( Timeout => 5, Prompt => '/%/', Host => $hostname); $t->open($hostname); $t -> waitfor('/login:/'); $t->print('admin'); $t->waitfor('/Password:/'); $t->print('admin1'); print "script is now here\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: writing output to screen with telnet.pm
by shenme (Priest) on Oct 08, 2003 at 22:13 UTC | |
by splatohara (Novice) on Oct 09, 2003 at 08:26 UTC | |
by shenme (Priest) on Oct 09, 2003 at 18:11 UTC | |
|
Re: writing output to screen with telnet.pm
by LTjake (Prior) on Oct 08, 2003 at 15:50 UTC | |
|
Re: writing output to screen with telnet.pm
by vek (Prior) on Oct 08, 2003 at 16:17 UTC |