SUMMARY ftp: ftp/tcp: unknown service

From: Dan Liebster (dl@willow.net)
Date: Mon Dec 22 1997 - 01:11:02 CST


Thanks to all the folks who replied!
I was deluged with scores of replies.
The original issue was..
>I have suddenly started recieving this mesage on an x86 2.6 box:
> "ftp: ftp/tcp: unknown service"
>whenever i try to ftp anywhere(localhost, or any other machine on the lan)
>>
>I get the same message for telnet
>I can ping just fine, though localhost and others on lan.
>I've rebooted several times too.
>(and inetd.conf lists ftp and telnet as active services)
The first group of replies said to check etc/services fot the ftp tcp
services.
That file was fine
The winning entries arrived within minutes from each other via "J.J.Bailey"
<jjb@bcc.com>,
  Mariel Feder <unix.support@meralco.com.ph>,and Jochen Bern
<bern@penthesilea.uni-trier.de>.
It turned out that the NIS+ map was corrupted, and nsswitch.conf was set to
only believe
NIS+, and not the files(ie. etc/services)
I deleted the " [NOTFOUND = return]" entry from the lines of nsswitch.conf
This resulted in the Box becomming social again, and accepting and
initiating telnet and
ftp sessions as normal.
Now its time to restore the NIS+ maps!
These fine folks also had the correct answer:
Jay Lessert jay_lessert@latticesemi.com
John Birtley <jbirtley@baesema.co.uk>
Eugene Kramer <eugene@uniteq.com>
Magnus Bergman <trident@trisec.net>
Thanks again to the many folks who so willingly lent their experience!
Since it was the first to hit the nail on the head, here is Mariel Feder's
response to the problem:
------------------------------
If Nis+ is running, check the /etc/nsswitch.conf for the entry for
services.
If you find an entry like:
services: nisplus [NOTFOUND=return] files
That means that the services are only looked in the nis+ tables, and the
local files are checked only if nis+ is down.
You have two options:
1-Check that the ftp service is registered in the nis+ services table
(niscat -h services.org_dir) and if it's not there, add it.
2-Change your nsswtich.conf to make it to look for the services table in
the local files also.
Entries like
services: files nisplus [NOTFOUND=return] (to look first in
local files)
or
services: nisplus files (not to abort if
it's not in the nis+ table)
I myself implemented option 1.
I inserted in the NIS+ table, all the entries from the /etc/services file.
Hope this helps
Mariel
------------------------------



This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:12:11 CDT