Question

I do use passive ftp in my software so that customer can download the software updates.Now my doubt is that if there are so many request to ftp(for downloading updates) then can passive ftp port can manage all requests?How does it work exactly?

Was it helpful?

Solution

A well-written generic server can handle tens of thousands of connections on a single port, no problem. The client IP/Port are part of the connection, so you can theoretically have millions of connections on a single port.

With FTP PASV transfers, the server provides an additional Port for your clients to connect to for transferring the file body outside of the control channel.

A naive server will simply bind a single ephemeral port per outstanding transfer. This will lead to an upper bound of well above 30,000.

Some FTP servers will let you configure a PASV port range which can make this number much smaller, which can restrict the number of concurrent users connected to your server in a naive implementation.

A more advanced FTP server implementation will allow multiple clients to connect to the PASV transfer ports, and use the clients' public IPs to manage which files are being requested or sent per public IP.

Realistically, if you're using a wide port range, you're more likely to run into bandwidth, CPU, Disk, or other system constraints on your server than you are to hit some kind of networking/port range limitation.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top