Saturday, July 6, 2019

unblock ip fail2ban

How to unban the banned ip in fail2ban

Its very simple to show the list of banned IPs in Fail2ban jail, first you have to select the jail, you want to show the blocked IPs.

To get the active jails types:-

# fail2ban-client status

You can see in the specific jail by using this command :-
#  fail2ban-client status
Eg
fail2ban-client status sshd

You can unblock IP in any any jail by using this command:-


fail2ban-client set  unbanip ip_here
Eg :-
# fail2ban-client set sshd unbanip 10.10.10.10
check the status :-
$ fail2ban-client status sshd

And IF you want to block IP manually in fail2ban jail :-

fail2ban-client set banip


Eg,
# fail2ban-client set sshd banip 10.10.10.10

Cheer!!! 

0 comments: