Alp*_*ran 7 ftp socket ipv4 vsftpd
我必须在我的机器上设置一个 FTP 服务器。我已经使用以下命令安装了 vsftpd:
sudo apt-get install vsftpd
Run Code Online (Sandbox Code Playgroud)
然后我编辑vsftpd.conf
了位置中的配置文件/etc
。该文件包含:
#Set the server to run in standalone mode
listen=YES
#Enable anonymous access
local_enable=NO
anonymous_enable=YES
#Disable write access
write_enable=NO
#Set root directory for anon connections
anon_root=/var/ftp
#Limit retrieval rate
anon_max_rate=2048000
#Enable logging user login and file transfers. /var/log/vsftpd.log
xferlog_enable=YES
#Set interface and port
listen_address=192.120.43.250
listen_port=21
Run Code Online (Sandbox Code Playgroud)
IP 地址 192.120.43.250 是我服务器的 eth0。当我运行命令时
sudo vsftpd /etc/vsftpd.conf
Run Code Online (Sandbox Code Playgroud)
我收到错误:
500 OOPS: could not bind listening IPv4 socket
Run Code Online (Sandbox Code Playgroud)
要检查端口 21 上正在运行的内容,我运行了以下命令:
sudo netstat -tulpn
Run Code Online (Sandbox Code Playgroud)
看到 vsftpd 进程 ID 是29383,所以我发出了命令:
sudo killserver 29383
Run Code Online (Sandbox Code Playgroud)
并再次检查。将vsftpd
仍然存在,但有不同的PID。运行命令:
sudo killall vsftpd
Run Code Online (Sandbox Code Playgroud)
和
sudo killall -9 vsftpd
Run Code Online (Sandbox Code Playgroud)
做同样的事情。我已经尝试重新安装。任何人都知道发生了什么以及如何解决它?
小智 7
记得注释掉
listen=YES
Run Code Online (Sandbox Code Playgroud)
在您的vsftpd.conf
文件中,这样您就不会vsftpd
在独立模式下运行
它解决了我的问题。
归档时间: |
|
查看次数: |
35727 次 |
最近记录: |