use strict; use warnings; use IO::Socket; my $socket = IO::Socket::INET->new(PeerAddr => 'isfe', PeerPort => 4444, Type => SOCK_STREAM); die $@ unless $socket; print $socket "hello\n"; close($socket);