[root@somehost]ftp localhost
Connected to localhost.localdomain.
220 (vsFTPd 1.2.1)
Name (localhost:admin): bobsmith (很明显,你必须使用在你的服务器上的有效用户)
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
150 Here comes the directory listing.
-rw-r--r-- 1 1001 1001 25372 Jan 17 18:50 somefile.tar.gz
drwx------ 2 1001 1001 512 Jan 16 19:16 index.htm
226 Directory send OK.
ftp> quit
221 Goodbye.
[root@somehost]
vi /etc/xinetd.d/vsftpd
# default: off
# description: The vsftpd FTP server serves FTP connections. It uses \
# normal, unencrypted usernames and passwords for authentication.
service ftp
{
disable = no
socket_type = stream
wait = no
user = root
server = /usr/sbin/vsftpd
nice = 10
}
保存并退出.
现在停止并重启xinetd...
代码如下:
/etc/rc.d/init.d/xinetd restart
现在来测试inetd/xinetd ftp服务器:
代码如下:
[root@somehost]ftp localhost
Connected to localhost.localdomain.
220 (vsFTPd 1.2.1)
Name (localhost:admin): bobsmith (很明显,你必须使用在你的服务器上的有效用户)
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
150 Here comes the directory listing.
-rw-r--r-- 1 1001 1001 25372 Jan 17 18:50 somefile.tar.gz
drwx------ 2 1001 1001 512 Jan 16 19:16 index.htm
226 Directory send OK.
ftp> quit
221 Goodbye.
[root@somehost]