Thank you,
Patrick Sullivan
Centura
Health
-----Original Message-----
From: Mundell, R. (Ronald) [mailto:[EMAIL PROTECTED]
Sent: Monday, July 07, 2003 5:20 AM
To: Perl-Unix-Users (E-mail); Perl-Win32-Users (E-mail)
Subject: [Perl-unix-users] Telnet to AIXGood Day All
I am experiencing some strange problems when I telnet to an AIX Unix box. I login Successful, but when I execute a unix call eg. ls -l it does not return any data. If someone knows how to solve this problem or got some advise please help
#!/usr/bin/perl -w
use strict;use Net::Telnet();
my $Servers = qw|goblin|;
my $username = qq|test|;
my $password = qq|12345|;
my $timeout = 30;my $t = new Net::Telnet( Timeout => $timeout, Prompt => '/[\w:\w:\w+]$/' );
print qq|Open $Server\n|;
$t->open ( qq|$Server| );
print qq|Login $Server\n|;
$t->login ( $username, $password );
print qq|Done Login $Server\n|;
foreach my $user ( sort @UserList )
{
chomp $user;
my $hostname = $t->cmd ( qq|hostname| );
print qq|Hostname: $hostname\n|;
my (@forecast) = $t->cmd ( qq|ls -l| );
print qq|@forecast\n|;
}Thank you,
Ronald Mundell
Technical Specialist
Information Security
EF24
105 West Street
Sandton
Tel: 011 8813751(W)
0834111107(C)
This email and any accompanying attachments may contain confidential and proprietary information. This information is private and protected by law and, accordingly, if you are not the intended recipient, you are requested to delete this entire communication immediately and are notified that any disclosure, copying or distribution of or taking any action based on this information is prohibited.
Emails cannot be guaranteed to be secure or free of errors or viruses. The sender does not accept any liability or responsibility for any interception, corruption, destruction, loss, late arrival or incompleteness of or tampering or interference with any of the information contained in this email or for its incorrect delivery or non-delivery for whatsoever reason or for its effect on any electronic device of the recipient.
If verification of this email or any attachment is required, please request a hard-copy version.
This communication is for the use of the intended recipient only. It may contain information that is privileged and confidential. If you are not the intended recipient of this communication, any disclosure, copying, further distribution or use thereof is prohibited. If you have received this communication in error, please advise me by return e-mail or by telephone and delete/destroy it.