1827811 Members
1907 Online
109969 Solutions
New Discussion

Re: ftp issue

 
SOLVED
Go to solution
infarakesh
Advisor

Re: ftp issue

# cat /etc/services|grep -i ftp
ftp-data 20/tcp # File Transfer Protocol (Data)
ftp 21/tcp # File Transfer Protocol (Control)
tftp 69/udp # Trivial File Transfer Protocol
sftp 115/tcp # Simple File Transfer Protocol
bftp 152/tcp # Background File Transfer Protocol
ftp-ftam 8868/tcp # FTP->FTAM Gateway
#

# cat /etc/nsswitch.conf
#
# /etc/nsswitch.nis:
#
# @(#)B11.23_LR
#
# An example file that could be copied over to /etc/nsswitch.conf; it
# uses NIS (YP) in conjunction with files.
#

passwd: compat
#passwd: files nis
group: compat
#group: files nis
hosts: nis [NOTFOUND=return] files
ipnodes: files
networks: nis [NOTFOUND=return] files
protocols: nis [NOTFOUND=return] files
rpc: nis [NOTFOUND=return] files
publickey: nis [NOTFOUND=return] files
netgroup: nis [NOTFOUND=return] files
automount: files nis
aliases: files nis
services: files
#


# netstat -an|grep '*.21'
tcp 0 0 *.2121 *.* LISTEN
tcp 0 0 *.2148 *.* LISTEN
udp 0 0 *.2121 *.*
udp 0 0 *.2148 *.*
#
Patrick Wallek
Honored Contributor

Re: ftp issue

Above you said /etc/inetd.conf has:

ftp stream tcp nowait root /usr/lbin/ftpd ftpd -l
ftp stream tcp6 nowait root /usr/lbin/ftpd ftpd -l

Try commenting out the ftp line that has tcp6 in it and run 'inetd -c' again.

Also, can you attach a copy of the /etc services file? There still appears to be something wrong there.

Also:

ls -l /etc/services /etc/inetd.conf /etc/nsswitch.conf
infarakesh
Advisor

Re: ftp issue

commented tcp6 and ran "inetd -c". same result.

attaching services file as txt format.

# ls -l /etc/services /etc/inetd.conf /etc/nsswitch.conf
-rw-r--r-- 1 root sys 4892 May 31 21:51 /etc/inetd.conf
-rw-r--r-- 1 root sys 591 May 31 16:58 /etc/nsswitch.conf
-rw-r--r-- 1 bin bin 11545 May 31 14:53 /etc/services



Thanks in advance for all your time!!
Steven Schweda
Honored Contributor
Solution

Re: ftp issue

man nsswitch.conf

On my 11.31 system, it says:

[...]
WARNINGS
Within each process that uses nsswitch.conf(), the entire file is read
only once. If the file is later changed, the process will continue
using the old configuration.
[...]

So, "inetd -c" (or "kill -HUP") may not be
enough. You may need to stop and restart the
inetd process to get it to see any changes in
the name resolution configuration.

> You could also re-boot the system to restart
> inetd, but that shouldn't be necessary.

But it might have worked better than "inetd
-c". "-k" (followed by a manual restart)
might do more than "-c".
infarakesh
Advisor

Re: ftp issue

wow, that did the trick.

did "inetd -k" and then inetd. ftp is working finr now
infarakesh
Advisor

Re: ftp issue

force restart of inetd did the trick