Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"no directory /var/run/fail2ban to contain the socket file" #35

Closed
7yl4r opened this issue Jun 27, 2017 · 2 comments
Closed

"no directory /var/run/fail2ban to contain the socket file" #35

7yl4r opened this issue Jun 27, 2017 · 2 comments
Labels
needs-feedback Further information is requested

Comments

@7yl4r
Copy link

7yl4r commented Jun 27, 2017

I'm seeing this error on (only) one of my nodes where the same configuration is working on other similar nodes.

Usage is simply:

	class { 'fail2ban':
		config_file_template => "fail2ban/${codename}/etc/fail2ban/jail.conf.erb",
		package_ensure       => 'latest',
	}
Error: Systemd start for fail2ban failed!
journalctl log for fail2ban:
-- Logs begin at Fri 2017-06-23 21:32:14 UTC, end at Tue 2017-06-27 19:57:29 UTC. --
Jun 27 19:57:29 myServer systemd[1]: Starting Fail2Ban Service...
Jun 27 19:57:29 myServer fail2ban-client[26333]: ERROR  There is no directory /var/run/fail2ban to contain the socket file /var/run/fail2ban/fail2ban.sock.
Jun 27 19:57:29 myServer systemd[1]: fail2ban.service: control process exited, code=exited status=255
Jun 27 19:57:29 myServer systemd[1]: Failed to start Fail2Ban Service.
Jun 27 19:57:29 myServer systemd[1]: Unit fail2ban.service entered failed state.
Jun 27 19:57:29 myServer systemd[1]: fail2ban.service failed.

...

Notice: /Stage[main]/Fail2ban/Anchor[fail2ban::end]: Dependency Service[fail2ban] has failures: true
Warning: /Stage[main]/Fail2ban/Anchor[fail2ban::end]: Skipping because of failed dependencies

attempted workaround

I tried mkdir /var/run/fail2ban && chmod 777 /var/run/fail2ban before puppet agent --test and now I get /var/run/fail2ban exists but not accessible for writing

Jun 27 20:17:35 myServer fail2ban-client[25399]: ERROR  Directory /var/run/fail2ban exists but not accessible for writing
Jun 27 20:17:35 myServer systemd[1]: fail2ban.service: control process exited, code=exited status=255
Jun 27 20:17:35 myServer systemd[1]: Failed to start Fail2Ban Service.
Jun 27 20:17:35 myServer systemd[1]: Unit fail2ban.service entered failed state.
Jun 27 20:17:35 myServer systemd[1]: fail2ban.service failed.

Which is weird because

[me@myServer ~]# ll /var/run/
drwxrwxrwx.  2 root    root     40 Jun 27 19:59 fail2ban

Node info:

  • CentOS Linux release 7.2.1511 (Core).
@dhoppe
Copy link
Member

dhoppe commented Apr 21, 2020

Does the problem still exist?

@dhoppe dhoppe added the needs-feedback Further information is requested label Apr 21, 2020
@7yl4r
Copy link
Author

7yl4r commented Jan 19, 2021

The node to which I was referring no longer exists. I'm closing this until another similar report comes in.

@7yl4r 7yl4r closed this as completed Jan 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-feedback Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants