Results 1 to 7 of 7

Thread: fail2ban help

  1. #1

    Default fail2ban help

    I have installed the lastest version of fail2ban via yast2, in opensuse 10.3
    I can not get the server to connect-it says;
    ERROR Unable to contact server. Is it running?
    even though all the files installed correctly!
    I am new to Linux and have Guarddog running as a firewall, any help would be great as im lost how to configure it for opensuse 10.3 so it will;
    -start on startup
    -run with no errors etc

    thank you!
    from becca

  2. #2
    Join Date
    Jan 2008
    Location
    U.K East Anglia
    Posts
    2,581

    Default Re: fail2ban help

    Have a look in YaST - System -System Services (Runlevel ) & make sure it is activated there

    Andy
    To be is to do = Immanuel Kant
    To do is to be = Descartes.
    Do be do be do = Frank Sinatra

    SuSE user since 7.0,Linux user since 1994

  3. #3

    Default Re: fail2ban help

    hi andy
    i did what you said and i got the following message:
    to start service fail2ban and enable it at runlevels 3,5 these services must be additionally started and enabled, because it depends on them:
    boot.clock

    then it presents two options:
    continue
    exit

    I press continue then the following message comes up:
    /etc/init.d/boot.clock start returned 0 (success):
    /etc/init.d/fail2ban start returned 0 (success):

    I press okay then finish on the system services (runlevel) and it saves, but when i check status in the terminal with the following command;

    fail2ban-client status

    I get:
    ERROR Unable to contact server. Is it running?

    then when i try the following command;
    fail2ban-client start

    i get:
    ERROR No file found for /var/log/sshd.log
    ERROR No file found for /var/log/postfix.log
    ERROR No file found for /var/log/vsftpd.log
    ERROR No file found for /var/log/sshd.log
    ERROR No file found for /var/log/apache*/*error.log
    ERROR No file found for /home/www/myhomepage/error.log
    ERROR No file found for /var/log/apache2/error_log
    ERROR No file found for /var/log/proftpd/proftpd.log
    ERROR No file found for /var/www/*/logs/access_log
    ERROR No file found for /var/log/vsftpd.log
    ERROR No file found for /var/log/mail.log
    2008-10-30 19:45:20,842 fail2ban.server : INFO Starting Fail2ban v0.8.3
    2008-10-30 19:45:20,843 fail2ban.server : INFO Starting in daemon mode
    ERROR Could not start server. Maybe an old socket file is still present. Try to remove /var/run/fail2ban/fail2ban.sock. If you used fail2ban-client to start the server, adding the -x option will do it


    thank you for all the help!

  4. #4
    Join Date
    Jun 2008
    Location
    Europe
    Posts
    405

    Default Re: fail2ban help

    So... As suggested in these error log, have you tried to remove the /var/run/fail2ban/fail2ban.sock file ?

    That's what i did for my fail2ban to start. And now it works like a charm.

  5. #5

    Default Re: fail2ban help

    i deleted the old sock but still get this message;
    ERROR No file found for /var/log/sshd.log
    ERROR No file found for /var/log/postfix.log
    ERROR No file found for /var/log/vsftpd.log
    ERROR No file found for /var/log/sshd.log
    ERROR No file found for /var/log/apache*/*error.log
    ERROR No file found for /home/www/myhomepage/error.log
    ERROR No file found for /var/log/apache2/error_log
    ERROR No file found for /var/log/proftpd/proftpd.log
    ERROR No file found for /var/www/*/logs/access_log
    ERROR No file found for /var/log/vsftpd.log
    ERROR No file found for /var/log/mail.log
    2008-10-30 19:45:20,842 fail2ban.server : INFO Starting Fail2ban v0.8.3
    2008-10-30 19:45:20,843 fail2ban.server : INFO Starting in daemon mode

  6. #6

    Default Re: fail2ban help

    I managed to find the files in the error message, my config file had the logs directed to the wrong folders-whoops.
    Now i get this message when i type fail2ban-client status;

    ERROR Unable to contact server. Is it running?


    when i type fail2ban-client start i get;
    2008-10-31 18:30:44,499 fail2ban.server : INFO Starting Fail2ban v0.8.3
    2008-10-31 18:30:44,500 fail2ban.server : INFO Starting in daemon mode

  7. #7

    Default Re: fail2ban help

    fail2ban is working now thanks for the help!
    i also looked at this guide;
    The Art of Web ~ System: fail2ban and iptables


    thanks again!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •