fail2ban โ a set of server and client programs to limit brute force authentication attempts.
| Use Case | Command | Description |
|---|---|---|
| ๐ฅ๏ธ Start the server | fail2ban-server |
Start the fail2ban server daemon |
| ๐ Check status | fail2ban-client status |
Get current status of all jails |
| ๐ Manually ban an IP | fail2ban-client set <jail> banip <ip> |
Immediately ban an IP address in a specific jail |
| ๐ Manually unban an IP | fail2ban-client set <jail> unbanip <ip> |
Remove a ban for an IP address |
| ๐งช Test regex patterns | fail2ban-regex <log> <regex> |
Test regular expressions against log files |
| ๐ Reload configuration | fail2ban-client reload |
Reload configuration without restarting the server |
Fail2Ban consists of a client, server and configuration files to limit brute force authentication attempts.
The server program fail2ban-server is responsible for monitoring log files and issuing ban/unban commands. It gets configured through a simple protocol by fail2ban-client, which can also read configuration files and issue corresponding configuration commands to the server.
For details on the configuration of fail2ban see the jail.conf(5) manual page. A jail (as specified in jail.conf) couples filters and actions definitions for any given list of files to get monitored.
For details on the command-line options of fail2ban-server see the fail2ban-server(1) manual page.
For details on the command-line options and commands for configuring the server via fail2ban-client see the fail2ban-client(1) manual page.
For testing regular expressions specified in a filter using the fail2ban-regex program may be of use and its manual page is fail2ban-regex(1).
Fail2Ban is able to reduce the rate of incorrect authentications attempts however it cannot eliminate the risk that weak authentication presents. Configure services to use only two factor or public/private authentication mechanisms if you really want to protect services.
A local user is able to inject messages into syslog and using a Fail2Ban jail that reads from syslog, they can effectively trigger a DoS attack against any IP. Know this risk and configure Fail2Ban/grant shell access accordingly.
/etc/fail2ban/*
Manual page written by Daniel Black and Yaroslav Halchenko
Report bugs to https://github.com/fail2ban/fail2ban/issues
Copyright ยฉ 2013
Copyright of modifications held by their respective authors. Licensed under the GNU General Public License v2 (GPL).
fail2ban-server(1) fail2ban-client(1) fail2ban-regex(1) jail.conf(5)
Generated by phpman v4.10.0-7-g98e9fd5 · Markdown · JSON · MCP Author: Che Dong Under GNU General Public License
2026-09-04 06:56 @216.73.216.46
CrawledBy Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)