http://www.perlmonks.org?node_id=419915

Bharath has asked for the wisdom of the Perl Monks concerning the following question:

Hi, I tried a lot on the below problem but couldn't get the solution. Can anyone give a solution. I need to have a perl script on the client side that actively interacts with the agent on the server which runs as a inetd service. On server we have one agent (written in shell) which is run by inetd that continuosly listens client request and gives different responses depending on request. This agent is working fine. At client side we have perl script should open socket to server on 'xyz' port. send request to the server. Here I need to track the output of given request and depending on that I have to send next reqests sequentially. It should close the port only after all the requests are over (or any error on serving any particular request). Port should be opened only once for all requests.
  • Comment on client script for interacting with inetd service

Replies are listed 'Best First'.
Re: client script for interacting with inetd service
by gellyfish (Monsignor) on Jan 06, 2005 at 14:13 UTC

    You probably want to start by looking at the section entitled "TCP Clients with IO::Socket" in the perlipc manpage.

    /J\