sudo fail2ban-client set sshd banip 203.0.113.5

Category: VPS Management

sudo fail2ban-client set sshd banip 203.0.113.5

Manually ban an IP in the sshd jail

Instantly bans the address without waiting for it to trip the failure threshold — the right move when you spot an attacker in the logs. The ban is applied through the jail's firewall action, so it behaves like an automatic ban. Lift it with the matching unbanip when the threat is over.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.