header

Proftpd on FreeBSD delay after “Waiting for welcome message…”



I’ve run an FTP server for some time, and it was a minor problem to me that it would always lag a bit on connection. The connection would be something like this:

Status: Connecting to {server url}
Status: Connected with {server url}. Waiting for welcome message...
{10-20 second delay}
Response: 220 {Server Name} (the HELO)

That 10-20 second delay was caused by a DNS lookup, whether failed or succeeded I had no need for it. Truthfully in my /var/log/xferlog I’d rather see
24.20.96.1XX rather than
c-24-20-96-1XX.hsd1.wa.comcast.net

So to fix it, I added these lines to my /usr/local/etc/proftpd.conf:

#to enable faster logins
UseReverseDNS off
IdentLookups off

Then restarted the server


root@sam# /usr/local/etc/rc.d/proftpd.sh restart
Stopping proftpd.
Waiting for PIDS: 577.
Starting proftpd.
root@sam#

And wha-la, instead of it taking 20+ seconds to connect and authenticate with my server, it’s done within 3 seconds.



2 Comments »

  1. gravatar

    Steven Said,

    March 12, 2008 @ 8:44 am

    Thanks for this, worked perfectly.

  2. gravatar

    Slow FTP Login | Val Petruchek on web-development Said,

    July 30, 2010 @ 4:40 pm

    […] Thanks to Ray Dehler. […]

RSS feed for comments on this post · TrackBack URI

Leave a Comment

blogtimes