kwaping has asked for the wisdom of the Perl Monks concerning the following question:
#!/usr/bin/perl use strict; use warnings; # usage: ./ltsp_client.pl mac_address use Carp; use IO::Socket::INET; die "Could not create socket: $!" unless my $sock = IO::Socket::INET->new( PeerAddr => 'xxxx.xxxx.com', PeerPort => xxxx, Proto => 'tcp', Type => SOCK_STREAM, Timeout => 10, ); foreach my $cmd (@ARGV) { print $sock "$cmd\n" or die $!; } print $sock "EOT\n" or die $!; my @text = <$sock>; close($sock) or die $!; print @text;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: IO::Socket::INET and LTSP read-only filesystem
by NetWallah (Canon) on Apr 17, 2007 at 03:17 UTC | |
by kwaping (Priest) on Apr 17, 2007 at 15:05 UTC | |
|
Re: IO::Socket::INET and LTSP read-only filesystem
by Thelonius (Priest) on Apr 17, 2007 at 01:51 UTC | |
by kwaping (Priest) on Apr 17, 2007 at 14:57 UTC | |
|
Re: IO::Socket::INET and LTSP read-only filesystem
by ikegami (Patriarch) on Apr 17, 2007 at 22:11 UTC | |
|
Re: IO::Socket::INET and LTSP read-only filesystem
by glenn (Scribe) on Oct 17, 2008 at 15:17 UTC | |
by glenn (Scribe) on Oct 18, 2008 at 19:09 UTC |