centos7如何登錄ftp centos7搭建ftp服務(wù)器不成功.求助?
centos7搭建ftp服務(wù)器不成功.求助?1. 檢查是否安裝了vsftpd。RPM-QA | grep vsftpd 2。安裝Yum-y安裝vsftpd 3。啟動(dòng)服務(wù)并檢查安裝是否成功。服務(wù)vsft
centos7搭建ftp服務(wù)器不成功.求助?
1. 檢查是否安裝了vsftpd。
RPM-QA | grep vsftpd 2。安裝Yum-y安裝vsftpd 3。啟動(dòng)服務(wù)并檢查安裝是否成功。服務(wù)vsftpd狀態(tài)
2。專門(mén)創(chuàng)建新FTP服務(wù)器的用戶。這里我以ftpuser為例:Command:useradd ftpuser添加一個(gè)新用戶ftpuser passwd ftpuser設(shè)置ftpuser的密碼,在這個(gè)過(guò)程中會(huì)提示您確認(rèn)兩次密碼。3、 為FTP服務(wù)設(shè)置防火墻,默認(rèn)FTP端口為21,默認(rèn)不開(kāi)啟CentOS,因此修改iptables文件VI/etc/sysconfig/iptables-a input-ptcp-M state--state new-M TCP--dport 21-J accept finally:WQ save restart firewall:Service iptables restart注意:將iptables.service服務(wù)文件不存在。由于centos7默認(rèn)使用防火墻作為防火墻,因此將其更改為iptables firewall systemctl start防火墻服務(wù)#啟動(dòng)firewallsystemctl停止防火墻服務(wù)#停止firewallsystemctl禁用防火墻服務(wù)#禁用防火墻引導(dǎo)
更改以下21個(gè)端口到您的端口號(hào)注意設(shè)置SELinux或關(guān)閉SELinux firewall CMD--permanent--zone=public--add port=21/TCP,然后執(zhí)行reloading firewalld,set firewall CMD--reload,delete previous services,firewall CMD--permanent--remove server=TCP,list firewall open ports,firewall CMD--list all