+ -
当前位置:首页 → 问答吧 → ftpd为什么登陆不了啊?

ftpd为什么登陆不了啊?

时间:2005-04-29

来源:互联网

编辑了/etc/inetd.conf,去掉了ftpd部分的注释:
ftp stream tcp nowait root /usr/libexec/ftpd ftpd -l
然后重新启动inetd,netstat -na|grep 21
tcp4 0 0 *.21 *.* LISTEN
很明显ftpd已经起来拉。
那么我ftp localhost时,怎么老有连接拒绝的错误,但是可以成功登陆的:
bsd# ftp localhost
Trying ::1...
ftp: connect to address ::1: Connection refusedTrying 127.0.0.1...
Connected to localhost.
220 bsd.hhuc.edu.cn FTP server (Version 6.00LS) ready.
Name (localhost:cupid): cupid
331 Password required for cupid.
Password:
230 User cupid logged in.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp>
可惜从其他主机没有办法ftp到该ftp服务器,为什么啊?
应该是防火墙的问题吧,可是我可以telnet到这里的?怎么查看我的防火墙的配置呢?谢谢!

另外,这个ftpd软件是什么啊?我怎么pkg_info看不到啊?在/var/db/pkg下面也没有看到啊?
bsd# ls /var/db/pkg/
bitstream-vera-1.10 xorg-fonts-cyrillic-6.7.0
expat-1.95.8 xorg-fonts-encodings-6.7.0
fontconfig-2.2.3,1 xorg-fonts-miscbitmaps-6.7.0
freetype2-2.1.7_3 xorg-fonts-truetype-6.7.0
imake-6.7.0_2 xorg-fonts-type1-6.7.0
libXft-2.1.6 xorg-fontserver-6.7.0
perl-5.8.5 xorg-libraries-6.7.0_2
pkgconfig-0.15.0_1 xorg-manpages-6.7.0
png-1.2.6 xorg-nestserver-6.7.0
xorg-clients-6.7.0_4 xorg-printserver-6.7.0
xorg-documents-6.7.0 xorg-server-6.7.0_9
xorg-fonts-100dpi-6.7.0 xorg-vfbserver-6.7.0
xorg-fonts-75dpi-6.7.0 xterm-196_3

作者: cupid   发布时间: 2005-04-29

>>inetd中使用FreeBSD自带的ftpd,你的问题可能是防火墙的问题,可以看看你是否已经打开了防火墙,比如ipfw,查看rules,可以试试ipfw --list.

作者: Freebird   发布时间: 2005-04-29

bsd# ipfw list
ipfw: getsockopt(IP_FW_GET): Protocol not available
输出如上所示,说明了什么啊,我对ipfw不熟悉。

作者: cupid   发布时间: 2005-04-29

把你 /etc/rc.conf 里关于 ipfw , ipf 的内容 都注释掉。

保证 /etc/rc.conf 有inetd_enable="YES" 存在。

保证 /etc/inetd.conf 里ftpd 部分取消注释。

然后重起机器。

作者: likuku   发布时间: 2005-05-02