How to find and edit the file for fail2ban to change the email address it’s using to send banned ips too

emailfail2banubuntu-16.04

Running Ubuntu 16.04 OS
Nginx server
Fail2Ban Ver 0.9.3

When I first did the install of fail2ban i believe it asked me for an email address.

well, I put in my personal email and I get spammed with all the ips getting banned. I dont mind it but i want to change the email address it has. But, I'm unable to locate the correct file where i can change the email address it's sending too.

what is the filename I need to edit?
what directory is this file in?

Please help

Thanks,
Ronnie

Best Answer

You should be able to change the email address within the jail.conf

I use centos, but you should be able to search and find the same file.

/etc/fail2ban/jail.conf

#Sender email address used solely for some actions

sender = root@localhost