Bug 7871 - fail2ban doesn't start (missing /var/run/fail2ban directory)
Summary: fail2ban doesn't start (missing /var/run/fail2ban directory)
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Remco Rijnders
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-22 11:23 CEST by Stéphane Pontier
Modified: 2012-11-24 12:00 CET (History)
1 user (show)

See Also:
Source RPM: fail2ban-0.8.7.1-1.mga3.src.rpm
CVE:
Status comment:


Attachments

Description Stéphane Pontier 2012-10-22 11:23:42 CEST
Description of problem:
fail2ban refuse to start when booting my computer, in syslog I can find:
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

But the problem is that /var/run/fail2ban directory is missing. If I do:
sudo mkdir /var/run/fail2ban
sudo systemctl restart fail2ban.service
fail2ban is happy and start but at the next reboot, the directory is missing again.

I verified the installation with rpm -vV fail2ban and see that the /var/run/fail2ban is listed but flagged as missing.
Comment 1 Sander Lepik 2012-10-22 12:10:51 CEST
Some pointers for Remco:

you probably need similar %post part:
https://bugs.mageia.org/attachment.cgi?id=2865&action=diff

example of tmpfiles conf:
http://svnweb.mageia.org/packages/cauldron/munin/current/SOURCES/munin.tmpfiles?revision=283661&view=markup

More info on the topic: https://fedoraproject.org/wiki/Packaging:Tmpfiles.d

CC: (none) => sander.lepik

Remco Rijnders 2012-10-22 12:12:20 CEST

Status: NEW => ASSIGNED
Assignee: bugsquad => remco

Comment 2 Remco Rijnders 2012-11-11 05:54:44 CET
@Stéphane, thank you for your report.
@Sander, thank you for the pointers.

I've just submitted fail2ban-0.8.7.1-2, which I believe resolves this issue. Feel free to reopen this report if this problem persists.

Status: ASSIGNED => RESOLVED
Hardware: i586 => All
Resolution: (none) => FIXED

Comment 3 Stéphane Pontier 2012-11-13 11:25:34 CET
Hi, just after upgrading the package, fail2ban started succesfully (I didnt created the /var/run/fail2ban directory when the computer started the morning). but after restarting the computer, I had to mkdir /var/run/fail2ban to get fail2ban started again.

Status: RESOLVED => REOPENED
Resolution: FIXED => (none)

Comment 4 Remco Rijnders 2012-11-23 08:17:52 CET
Hi Stéphane, sorry for having messed up the first time around. Please try again with the fail2ban-0.8.7.1-3 package. I hope this works for you as it does on my own machine.
Comment 5 Remco Rijnders 2012-11-24 12:00:28 CET
I believe this is now fixed. Reopen in case you disagree.

Status: REOPENED => RESOLVED
Resolution: (none) => FIXED


Note You need to log in before you can comment on or make changes to this bug.