• The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved Problem activating fail2ban

LaurentR2D2

Plesk Certified Professional
Plesk Certified Professional
Hello,
My server specifications :

Debian 9.13
Plesk Obsidian Version 18.0.41 Mise à jour 1, dernière mise à jour le 9 Fév 2022 06:27

I can't activate fail2ban. When I check Activate fail2ban and click on Apply, I get a message telling me that settings have been saved, but the check box is unchecked, and fail2ban is not activated. I have no message telling me why.

Thank you
 

Attachments

  • fail2ban.log.1.zip
    9.9 KB · Views: 6
Hi,

What is the output of this command?

systemctl status fail2ban

Can you start it from the commandline?

systemctl start fail2ban
 
Hi,

What is the output of this command?

systemctl status fail2ban

Can you start it from the commandline?

systemctl start fail2ban
systemctl status fail2ban
● fail2ban.service - Fail2Ban Service
Loaded: loaded (/lib/systemd/system/fail2ban.service; enabled; vendor preset: enabled)
Drop-In: /lib/systemd/system/fail2ban.service.d
└─50-ensure-log.conf
Active: failed (Result: exit-code) since Wed 2022-02-16 23:33:30 CET; 10h ago
Docs: man:fail2ban(1)
Process: 19772 ExecStop=/usr/bin/fail2ban-client stop (code=exited, status=255)
Process: 19768 ExecStart=/usr/bin/fail2ban-server -xf start (code=exited, status=255)
Process: 19764 ExecStartPre=/bin/sh -c umask 077; touch /var/log/fail2ban.log (code=exite
Process: 19761 ExecStartPre=/bin/mkdir -p /run/fail2ban (code=exited, status=0/SUCCESS)
Main PID: 19768 (code=exited, status=255)
CPU: 164ms

Warning: Journal has been rotated since unit was started. Log output is incomplete or unava

I have no output when I launch systemctl start fail2ban. When I try the status command after the start command, I get that :

systemctl status fail2ban
● fail2ban.service - Fail2Ban Service
Loaded: loaded (/lib/systemd/system/fail2ban.service; enabled; vendor preset: enabled)
Drop-In: /lib/systemd/system/fail2ban.service.d
└─50-ensure-log.conf
Active: failed (Result: exit-code) since Thu 2022-02-17 10:17:05 CET; 52s ago
Docs: man:fail2ban(1)
Process: 26715 ExecStop=/usr/bin/fail2ban-client stop (code=exited, status=255)
Process: 26709 ExecStart=/usr/bin/fail2ban-server -xf start (code=exited, status=255)
Process: 26705 ExecStartPre=/bin/sh -c umask 077; touch /var/log/fail2ban.log (code=exite
Process: 26703 ExecStartPre=/bin/mkdir -p /run/fail2ban (code=exited, status=0/SUCCESS)
Main PID: 26709 (code=exited, status=255)
CPU: 162ms

Feb 17 10:17:05 minouchat systemd[1]: Starting Fail2Ban Service...
Feb 17 10:17:05 minouchat systemd[1]: Started Fail2Ban Service.
Feb 17 10:17:05 minouchat fail2ban-server[26709]: 2022-02-17 10:17:05,695 fail2ban
Feb 17 10:17:05 minouchat fail2ban-server[26709]: 2022-02-17 10:17:05,704 fail2ban
Feb 17 10:17:05 minouchat systemd[1]: fail2ban.service: Main process exited, code=exited, s
Feb 17 10:17:05 minouchat fail2ban-client[26715]: 2022-02-17 10:17:05,761 fail2ban
Feb 17 10:17:05 minouchat systemd[1]: fail2ban.service: Control process exited, code=exited
Feb 17 10:17:05 minouchat systemd[1]: fail2ban.service: Unit entered failed state.
Feb 17 10:17:05 minouchat systemd[1]: fail2ban.service: Failed with result 'exit-code'
 
Please change the log level in /etc/fail2ban/fail2ban.conf to DEBUG, then restart again, then change it back to INFO. Debugging level logging should give more information on the reason for the sudden death of the service. The current log level is not enough as it only logs that fact that Fail2Ban is stopped, but not the cause.
 
Please change the log level in /etc/fail2ban/fail2ban.conf to DEBUG, then restart again, then change it back to INFO. Debugging level logging should give more information on the reason for the sudden death of the service. The current log level is not enough as it only logs that fact that Fail2Ban is stopped, but not the cause.
I've done that, and I still have no message when launching start, and when I launch status I get that :

fail2ban.service - Fail2Ban Service
Loaded: loaded (/lib/systemd/system/fail2ban.service; enabled; vendor preset: enabled)
Drop-In: /lib/systemd/system/fail2ban.service.d
└─50-ensure-log.conf
Active: failed (Result: exit-code) since Thu 2022-02-17 10:37:38 CET; 40s ago
Docs: man:fail2ban(1)
Process: 27192 ExecStop=/usr/bin/fail2ban-client stop (code=exited, status=255)
Process: 27186 ExecStart=/usr/bin/fail2ban-server -xf start (code=exited, status=255)
Process: 27182 ExecStartPre=/bin/sh -c umask 077; touch /var/log/fail2ban.log (code=exited, status=0/SUCCESS)
Process: 27180 ExecStartPre=/bin/mkdir -p /run/fail2ban (code=exited, status=0/SUCCESS)
Main PID: 27186 (code=exited, status=255)
CPU: 158ms

Feb 17 10:37:38 minouchat systemd[1]: Starting Fail2Ban Service...
Feb 17 10:37:38 minouchat systemd[1]: Started Fail2Ban Service.
Feb 17 10:37:38 minouchat fail2ban-server[27186]: 2022-02-17 10:37:38,145 fail2ban [27186]: ERROR Failed during configuration: Have not found any log file for ssh jail
Feb 17 10:37:38 minouchat fail2ban-server[27186]: 2022-02-17 10:37:38,145 fail2ban [27186]: ERROR Async configuration of server failed
Feb 17 10:37:38 minouchat systemd[1]: fail2ban.service: Main process exited, code=exited, status=255/n/a
Feb 17 10:37:38 minouchat fail2ban-client[27192]: 2022-02-17 10:37:38,201 fail2ban [27192]: ERROR Failed to access socket path: /var/run/fail2ban/fail2ban.sock. Is fail2ban runn
Feb 17 10:37:38 minouchat systemd[1]: fail2ban.service: Control process exited, code=exited status=255
Feb 17 10:37:38 minouchat systemd[1]: fail2ban.service: Unit entered failed state.
Feb 17 10:37:38 minouchat systemd[1]: fail2ban.service: Failed with result 'exit-code'.
 
Back
Top