I installed fail2ban on ubuntu 16 on which I also have ufw. I copied jail.conf to jail.local in /etc/fail2ban. After this, I tried starting fail2ban but I get the following error in the logs (using the command systemctl status fail2ban.service):
fail2ban.service: Control process exited, code=exited status=255
abcdefgh systemd[1]: Failed to start Fail2Ban Service.
fail2ban.service: Unit entered failed state.
Any thoughts on how I go about troubleshooting this issue further?
Update The change I made to the jail.conf file was for the sshd section:
[sshd]
enabled = true
port = valid-ssh-port (this is a number but not the default port)
filter = sshd
logpath = /var/log/auth.log
maxretry = 5
There was an additional ssh section in the jail.local file which I had not checked for beforehand. Once I removed the additional ssh section, the config worked and I was able to run fail2ban.