Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 9 of 9
  1. #1
    Member
    Join Date
    Aug 2007
    Posts
    12

    Default FTP Passive Mode not working

    For some reason passive mode isn't working correctly on my server. It keeps timing out. Active mode works just fine, its just passive thats having the issue.

    I have csf installed and have MONOLITHIC_KERNEL set to 1 with the passive ftp ports set in TCP_IN "30000:50000"

    And have uncomented the line

    #PassivePortRange 35000 50000

    But I'm still having no luck fixing this issue. Any ideas?

  2. #2
    Member
    Join Date
    Aug 2007
    Posts
    11

    Default Passive FTP setting

    I have got the same problem. Even I have try this:

    iptables -A INPUT -p tcp --dport 30000:50000 -j ACCEPT

    Does anyone can reply me??

  3. #3
    Member
    Join Date
    Aug 2007
    Posts
    11

    Default csf and iptables

    I am using the csf 3.13 and added the ports 30000:50000 into the firewall configration. However, each time I restart the firewall (in Cpanel interface) or reboot, the passive mode cannot be done.

    On the other hand, I have manually added the ports to iptables, when I restart the iptables service, the passive FTP is work! When I restart the csf, it will be failed again. Does anyone got any ideas? I have checked many and many times in the csf firewall configration. Please give me a hand. Many thanks.

  4. #4
    Member
    Join Date
    Aug 2007
    Posts
    12

    Default

    Still no luck with this problem.

  5. #5
    Member Zepplin's Avatar
    Join Date
    Oct 2006
    Location
    Blue Mountains, Australia
    Posts
    84
    cPanel/Enkompass Access Level

    Root Administrator

    Default

    Did you try csf forum? http://forum.configserver.com/

  6. #6
    Super Moderator This forum account has been confirmed by cPanel staff to represent a vendor. chirpy's Avatar
    Join Date
    Jun 2002
    Location
    Go on, have a guess
    Posts
    13,495

    Default

    Quote Originally Posted by hicks8 View Post
    For some reason passive mode isn't working correctly on my server. It keeps timing out. Active mode works just fine, its just passive thats having the issue.

    I have csf installed and have MONOLITHIC_KERNEL set to 1 with the passive ftp ports set in TCP_IN "30000:50000"

    And have uncomented the line

    #PassivePortRange 35000 50000

    But I'm still having no luck fixing this issue. Any ideas?
    If you've done that you haven't opened the same passive port range hole in both csf and pure-ftpd. You need to follow all the steps under monolothic_kernel as they're mentioned in csf.conf for it to work on a VPS. This all stems from the fact that Virtuozzo have a broken connection tracking module for ftp in their VPS kernels. If the full steps in csf.conf don't work, then there's likely a configuration issue with the VPS as most VPS providers have no problems at all configuring the VPS clients for the correct iptables environment. We do all our csf testing on a ServInt VPS and it works without issue. However, since it isn't a real server there's always potential pitfalls. The Xen virtual server appear to work without any problems out of the box.
    Last edited by chirpy; 03-28-2008 at 10:31 AM.
    Jonathan Michaelson

    Need your cPanel servers secured and tuned?
    cPanel Server Configuration, Security, Recovery and Antivirus/AntiSpam Services
    Developers of the most effective (and free) Firewall & Security Solution for cPanel Servers - csf
    http://www.configserver.com

  7. #7
    cPanel Partner NOC cPanel Partner NOC Badge
    Join Date
    May 2007
    Location
    chicago, IL
    Posts
    24

    Default

    Adding to this older thread in case someone still has issues. In VMWare we recently increased the amount of vcpu from 1 to 2 and passive FTP stopped working with CSF.

    I made the changes in CSF and pure-ftpd.conf as documented here and all over but with no avail. Not all of my guests were updated in the maintenance window so I did an 'lsmod | grep conn' and noticed the updated guests in VMware had 'ip_conntrack' only, and the guests with 1 vcpu had 'ip_conntrack' and 'ip_conntrack_ftp' but the kernel versions were the same on both guests.

    Definitely an iptables thing. The fix was to 'modprobe ip_conntrack_ftp' and add ip_conntrack_ftp into /etc/sysconfig/iptables-config so upon bootup the module will load again.

    Please note that ip6tables-config exists as well for those of you using IPV6.

  8. #8
    Member cwalke32477's Avatar
    Join Date
    Mar 2010
    Location
    Atlanta, Georgia
    Posts
    94
    cPanel/Enkompass Access Level

    Root Administrator

    Default Re: FTP Passive Mode not working

    Sorry to bump such an old and decrepid thread, but it was the only I could find that pinpointed my issue.
    Everyone else was just the typical open the passive ports in the .conf etc. etc.

    Definitely an iptables thing. The fix was to 'modprobe ip_conntrack_ftp' and add ip_conntrack_ftp into /etc/sysconfig/iptables-config so upon bootup the module will load again.
    I ran the modprobe ip_conntrack_ftp and it is working
    However, where do I add it to the iptables-config so it will work on boot?
    Chris Walker
    http://www.siterack.net
    Reseller Hosting - HostReady® VPS Servers - Dedicated Servers

  9. #9
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    6,305
    cPanel/Enkompass Access Level

    Root Administrator

    Default Re: FTP Passive Mode not working

    I would imagine that ip_conntrack_ftp is one of the modules, so probably this would be the line where you would add the module:

    Code:
    IPTABLES_MODULES="ip_conntrack_netbios_ns"
    You would want to have spaces separating it, so it would probably look like the following:

    Code:
    IPTABLES_MODULES="ip_conntrack_netbios_ns ip_conntrack_ftp"
    Or, whatever else is already in your modules list for it at /etc/sysconfig/iptables-config and I would highly suggest doing this only after you have physical access to the machine in case anything occurs where it won't boot up after making the change.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Forums Technical Analyst, cPanel Tech Support

    Submit a ticket | Check an existing ticket

Similar Threads & Tags
Similar threads

  1. Passive FTP for cpbackup not working
    By dansgalaxy in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 04-13-2011, 03:04 PM
  2. Ftp not entring passive mode
    By mahmood in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 01-31-2008, 09:02 PM
  3. PureFTP Passive Mode
    By janus_atw in forum cPanel and WHM Discussions
    Replies: 10
    Last Post: 01-06-2008, 12:48 AM
  4. Why entering passive mode FTP, both with proftp/pureftp - all accounts
    By pingo in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 03-31-2004, 02:17 PM
  5. FTP Passive mode
    By minalia in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 06-11-2003, 04:37 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube