Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a java server console program that I have configured xinetd to start when connection comes in on a given port and then the program runs in an infinite loop receiving inputstream from telephone exchanges.

The thing is, when a new chunk of stream comes from the exchange xinetd forks a new process each time. I tried setting the wait parameter to yes and restarted the deamon, but no success.

How can I stop this behavior and have the deamon just direct the stream to the process already running? Am I missing something in my config or is it just incorrect?

My config is as follows:

        instances               = 60
        log_type                = SYSLOG authpriv
        log_on_success          = HOST PID
        log_on_failure          = HOST
        cps                     = 50 10
includedir /etc/xinetd.d

And then my actual config,

service aos_larmar
         socket_type         = stream
         protocol            = tcp
         user                = root
         type                = UNLISTED
         wait                = yes
     instances           = 256
         server              = /home/gunnl/java/
         port                = 5204
         disable             = no

My server OS is
Red Hat Enterprise Linux ES release 4 (Nahant Update 7)

share|improve this question

xinetd works by forking a new process for each connection, and the connection is closed when the process ends. If you have a persistent process then you should look at using something like netcat instead.

share|improve this answer
Should I then use something like "I nc -l -p 3000" ? – Gunnlaugur Apr 14 '11 at 18:54
Something like: On the receiving computer: nc -l 3141 (netcat, listen on port 3141) and on the sending computer nc -p 3141 (netcat, use port number). – Hennes Aug 31 '13 at 10:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.