Passive mode is always very important for ftp servers, if you are running csf firewall and cannot connect to ftp server then it means that range of passive ports is blocked in firewall. Here are simple steps
1) Add Passive Port range 30000-350000 to your Pureftp or Proftp configuration file
i) For Pure FTP
open /etc/pure-ftpd.conf, and this line
1 |
PassivePortRange 30000 35000 |
ii) For pro FTP
Open /etc/proftpd.conf, and add this line
1 |
PassivePorts 30000 35000 |
iii) Now add these ports in CSF config
Open /etc/csf/csf.conf
1 2 |
# Allow incoming TCP ports TCP_IN = "20,21,22,25,53,80,110,30000:35000" |
iv) restart csf and ftp
1 2 3 |
service csf restart service pureftpd restart (or) service proftpd restart |
Now you will not get error while connecting to ftp
Comment Policy:
Your words are your own, so be nice and helpful if you can. Please, only use your real name, not your business name or keywords. Using business name or keywords instead of your real name will lead to the comment being deleted. Anonymous commenting is not allowed either. Limit the amount of links submitted in your comment. We accept clean XHTML in comments, but don't overdo it please.