Messaging & Cache
Risk: High

Port 11211 β€” Memcached In-Memory Cache

Port 11211 is the default port for Memcached, a high-performance in-memory key-value caching system used to accelerate database-driven web apps.

PORT NUMBER

11211

PROTOCOL

TCP/UDP

DEFAULT PROCESS

memcached

FIREWALL TARGET

11211/tcp/udp

Instant Terminal Fixes for Port 11211

macOS & Linux Terminal
1. Check who is listening on port 11211:
echo stats | nc localhost 11211 || sudo lsof -i :11211
2. Kill process occupying port 11211 (EADDRINUSE fix):
sudo systemctl stop memcached || sudo killall memcached
3. UFW Firewall Allow rule:
sudo ufw allow from 127.0.0.1 to any port 11211 proto tcp
Windows PowerShell (Admin)
1. Check listening port:
Get-NetTCPConnection -LocalPort 11211
2. Force kill process on port 11211:
Stop-Service memcached -Force -ErrorAction SilentlyContinue
3. Docker Port Forwarding Mapping:
docker run -d -p 11211:11211 memcached:alpine memcached -m 64

Common Error Encountered

Memcached::get(): Failed to connect to server on port 11211: Connection refused.

Security Advisory & Hardening

Exposed UDP port 11211 was historically responsible for the largest DDoS reflection amplification attacks in internet history (>1.3 Tbps). Bind Memcached exclusively to 127.0.0.1 and disable UDP (-U 0).

Frequently Asked Questions

Port 11211 Questions & Answers

Common questions regarding default services, kill commands, and firewall configurations.

Port 11211 is commonly used for Memcached In-Memory Cache. Port 11211 is the default port for Memcached, a high-performance in-memory key-value caching system used to accelerate database-driven web apps.