Do you have a question? Post it now! No Registration Necessary
Subject
- Posted on
super super daemon inetd question ..
- 06-08-2007
June 8, 2007, 11:33 am

Hi
I would like to write a server app suports many protocols (TCP UDP
Telnet ..) and add it to inetd.conf launched by super daemon .
How should I write the inetd.conf , is ok to write like below ?
telnet stream tcp nowait root /sbin/app
How about raw TCP and UDP , should they add into configuration file use any
description ?
Thank you .
I would like to write a server app suports many protocols (TCP UDP
Telnet ..) and add it to inetd.conf launched by super daemon .
How should I write the inetd.conf , is ok to write like below ?
telnet stream tcp nowait root /sbin/app
How about raw TCP and UDP , should they add into configuration file use any
description ?
Thank you .

Re: super super daemon inetd question ..

There is a missing parameter at the end of the line. This is documented in
the man page for inetd.conf
http://www.linuxvalley.it/encyclopedia/ldp/manpage/man5/inetd.conf.5.php
The last last parameters are command line arguments for the program,
_including_ the name of the program as the first parameter e.g.
app stream tcp nowait root /sbin/app /sbin/app -v
You shoudl also check out the tcpd wrapper that can be used to configure
access to the app by allowing/disallowing access by IP address etc.
The other thing to note is that you get a separate invocation of /sbin/app
for each incoming TCP connection - which may or may not be what you want.
The main reasons for having services started by inetd (or xinetd) are...
- they are not running by default, leaving resources for other programs
- you can use tcpd for extra security
- easy of writing, you don't need to know much about handling
networking connections. You write your application to just
read from standard input and write to standard output and inetd
does the rest. You can even write your application in a scripting
language like bash, or perl.

You can not do raw TCP/UDP this way. Why do you need to do _RAW_ udp/tcp?

Site Timeline
- » ARM cross compile problem
- — Next thread in » Embedded Linux
-
- » Compact Flash - can only be used as not-removable!
- — Previous thread in » Embedded Linux
-
- » Crosscompiling for ARM: reloc type R_ARM_ABS32 is not supported for PIC - ...
- — Newest thread in » Embedded Linux
-
- » Fixed Point Arithmetic is a PITA!
- — The site's Newest Thread. Posted in » Electronics Design
-