use IPC::Run qw/run/; run ['/path/to/server'], \undef, sub { my $in = shift; chomp($in); print "<<$in>>\n"; };