Work out ephemeral port range instantly with clear inputs, formula shown and shareable results.
Each outbound connection consumes a local port for its lifetime plus the TIME_WAIT period, so the sustainable connection rate is port count divided by TIME_WAIT duration. The Linux default of 32768 to 60999 gives 28,232 ports, capping a single source-destination pair at roughly 470 new connections per second with a 60-second TIME_WAIT.
Port budget
ports = end - start + 1; required = connection rate x TIME_WAIT; max rate = ports / TIME_WAIT
The tuple is source IP, source port, destination IP and destination port, so the limit applies per destination pair. Many distinct destinations relieve the pressure; one busy upstream does not.
Connection reuse through keep-alive, which eliminates most port churn entirely. Widening the range and adding source addresses are secondary measures.