Fail2ban debian jessie Configuration

  • Hello,

    I've just updated debian 8 and the updated i-MSCP 1.2.4.
    But I encounter errors with fail2ban I had chosen this tutorial here:
    The service does not start and say for example:
    /var/log/apache2/users/*error.log does not exist.
    What should I put in place?

    Do you have a solution please?

    Thank you in advance

  • Hello ;

    This is not i-MSCP related.

    Thread moved.


  • oh excuse me, thank you moved.
    Does someone have a solution please?
    Thank you in advance

  • Hello,

    Thank you for your reply, I will try it and come back to you.

  • Hello again,

    I tried it and it works, thank you.
    But roundcube logs seems to have change of destination:

    juin 15 15:48:59 smtp fail2ban[27364]: Starting authentication failure monitor: fail2banERROR No file(s) found for glob /var/www/imscp/gui/public/tools/webmail/logs/errors
    juin 15 15:48:59 smtp fail2ban[27364]: ERROR Failed during configuration: Have not found any log file for roundcube jail
    juin 15 15:48:59 smtp fail2ban[27364]: failed!

    We need to: /var/www/imscp/gui/public/tools/webmail/logs/ ?

    Thank you in advance.

  • @raln

    Hello ;

    The log file will be automatically created by Roundcube once an error occurs (such as failed authentication). You could simply touch that file manually as follow to make your fail2ban happy:

    1. # touch /var/www/imscp/gui/public/tools/webmail/logs/errors
    2. # chown vu2000:vu2000 /var/www/imscp/gui/public/tools/webmail/logs/errors


  • Hello Nuxwin

    In fact it works much better, thank you to you :)
    Little question as to know what to put in: failregex = Because I like to put a prison for other script also rainloop the genre.

    Thank you in advance.

  • @raln

    For rainloop:

    1. [Definition]
    2. failregex = ^<HOST> -.*POST /rainloop/index.php\?/Ajax/0/ HTTP/1.1" 200
    3. ignoreregex =

    BTW: You could maybe use google a bit. We are not here to put everything in your hand ;)


  • I've updated the configuration file in wiki. Hope it works now.

    Edit: Added also rainloop to the wiki. Hope the path to the error-log is correct^^

    PS: Haven't tested it!