Fail2ban showing error Unable to contact server. Is it running?
We start fail2ban in centos using this command service fail2ban start but when we run service fail2ban status we get as below? What could be the mistake ya? Fail2ban (pid 2810 2813) is running... ERROR Unable to contact server. Is it running? We installed is from the epel source.
|
Quote:
Code:
ps -ef|grep fail2ban |
Dear Bathory,
Below is what I get when I run the command. root 1912 1891 0 07:42 pts/0 00:00:00 grep fail2ban |
Quote:
Regards |
Dear Bathory,
Under which file should I look for clue because I tried search most of the file for fail2ban I cant find much. I have tried /var/log/message but just tells me when it was installed only. |
Quote:
You may also try to start the server in the foreground and see if you get any errors Code:
fail2ban-server -f -s /var/run/fail2ban/fail2ban.sock |
Dear Bathory,
I tried this fail2ban-server -f -s /var/run/fail2ban/fail2ban.sock 2012-12-31 10:51:34,239 fail2ban.server : INFO Starting Fail2ban v0.8.4 and I just stuck here. I cant find any folder /var/log/fail2ban.log and /var/log/message have no information only for the installation of fail2ban. |
Quote:
Code:
ps -ef|grep fail2ban Code:
fail2ban-client status Regards |
Dear Bathory,
I have tried based on your link you gave so looks like it is a must to do the jail.conf copy into jail.local. I did that and then restart the fail2ban all is working well now as you can see below. That mean the missing part was there but what is the reason for the copy and why jail.local is the config file any reason? Quote:
Quote:
|
Quote:
Other than that, I don't see any reason why fail2ban was not starting at first. Maybe you had an error in the original jail.conf that you fixed after editing jail.local. Anyway, I'm glad it worked. You may mark the thread "Solved" fro the "Thread tools" on top of the page. Cheers |
Dear Bathory,
No I did not change anything to the copy at all. IS just the original version as it is? Now I am curious I am going to set another machine I think I must do the copy first? But where is the link saying to pick the configuration from jail.copy rather than jail.conf maybe this the one stopping it? |
All times are GMT -5. The time now is 12:39 PM. |