inetd fails to listen on IPv4 addresses

Bug #379621 reported by Paul Gear
28
This bug affects 5 people
Affects Status Importance Assigned to Milestone
inetutils (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: inetutils-inetd

On upgrade from intrepid to jaunty, my scanner stopped being accessible over the network, when i looked to find out why, i saw that saned was enabled, yet connections were being refused on port 6566. Checking netstat -pln, i found that inetd was only listening on IPv6:
 tcp6 0 0 :::6566 :::* LISTEN 29652/inetutils-ine

Here is the saned configuration line:
sane-port stream tcp nowait root /usr/sbin/saned saned

The documentation at http://www.gnu.org/software/inetutils/manual/html_section/Configuration-file.html says, "If IPv6 support is enabled the sockets will accept both IPv4 and IPv6 connections if that is supported by the OS." However, the only way i could get it to listen on IPv4 was to change tcp to tcp4 in inetd.conf. This seems wrong.

An unrelated issue is: i have never explicitly requested inetutils-inetd to be installed. It seems that both openbsd-inetd and xinetd are in main, whereas inetutils-inetd is in universe. I would be perfectly happy to run the preferred version of inetd (whatever that is) - i suspect there might be a bug relating to this either in the installer, or the saned package.

Revision history for this message
Andi Hechtbauer (anti-dotu) wrote :

to reproduce:

$ aptitude install inetutils-inetd
$ echo "2323 stream tcp nowait nobody /bin/true" |sudo tee -a /etc/inetd.conf
$ sudo /etc/init.d/inetutils-inetd restart
$ nc -v localhost 2323
localhost [127.0.0.1] 2323 (?) : Connection refused

compare this to:

$ echo "2323 stream tcp4 nowait nobody /bin/true" |sudo tee -a /etc/inetd.conf
$ sudo /etc/init.d/inetutils-inetd restart
$ nc -v localhost 2323
localhost [127.0.0.1] 2323 (?) open

Changed in inetutils (Ubuntu):
status: New → Confirmed
Revision history for this message
ykanello (ykanello) wrote :

I have the same issue. Actually mine NEVER listens to ipv4!
I have ipv6 removed from the sysctl.conf, (not blacklisted the modules yet as I need to reboot)
but inetd.conf loads only on ipv6 addresses:

netstat -anvp |grep 5666
tcp6 0 0 :::5666 :::* LISTEN 18271/inetutils-ine

root@annie:/etc/munin/plugins# tail -1 /etc/inetd.conf
nrpe stream tcp nowait nagios /usr/local/nagios/bin/nrpe /usr/local/nagios/bin/nrpe -c /etc/nrpe.cfg -i

This is so wrong in many ways :(
So wrong that I really consider never to use Ubuntu again.

Revision history for this message
ykanello (ykanello) wrote :

adding the tcp4 in the conf does fix the issue, but that makes the conf file incompatible with other systems!

Revision history for this message
Michel HANS (zfwd08) wrote :

This needs to be fixed as it probably causes problems with may utilities. I had the problem with 2 different today : telnet and nttcp.

nttcp specifies in the man page :

INSTALLATION
       To make most convenient use of this program, it can be installed on the partner machine, so that inetd(8) can start it. To accomplish this, two files have to be edited: /etc/inetd.conf and /etc/services.

       The respective lines may look like this:

       inetd.conf:
          ttcp stream tcp nowait nobody /usr/local/etc/nttcp nttcp

This issue makes therefore a lot of documentation inaccurate.

Same problem in 10.10

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.