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

FreeRADIUS stopped working after a recent upgrade on RHEL 8 #144

Closed
yann-soubeyrand opened this issue Jan 21, 2021 · 4 comments · Fixed by #194
Closed

FreeRADIUS stopped working after a recent upgrade on RHEL 8 #144

yann-soubeyrand opened this issue Jan 21, 2021 · 4 comments · Fixed by #194

Comments

@yann-soubeyrand
Copy link

yann-soubeyrand commented Jan 21, 2021

Hi,

After a FreeRADIUS upgrade on RHEL 8 (freeradius-3.0.20-3.module+el8.3.0+7597+67902674.x86_64), FreeRADIUS stopped working with this error in the logs:

Systemd start for radiusd failed!
journalctl log for radiusd:
-- Logs begin at Tue 2020-12-29 04:36:26 CET, end at Tue 2021-01-12 18:22:30 CET. --
Jan 12 18:22:30 <redacted> systemd[1]: Starting FreeRADIUS high performance RADIUS server....
Jan 12 18:22:30 <redacted> sh[1960192]: /bin/sh: /etc/raddb/certs/bootstrap: No such file or directory
Jan 12 18:22:30 <redacted> systemd[1]: radiusd.service: Control process exited, code=exited status=127
Jan 12 18:22:30 <redacted> systemd[1]: radiusd.service: Failed with result 'exit-code'.
Jan 12 18:22:30 <redacted> systemd[1]: Failed to start FreeRADIUS high performance RADIUS server..

I guess this is due to

purge => true,

What would be the best solution, keeping this file, or dropping a systemd override to prevent the service from calling this script as part of its ExecStartPre command?

@nward
Copy link
Collaborator

nward commented Feb 8, 2021

Hi @yann-soubeyrand

I think that a systemd override is the best solution here. Bootstrap running in systemd like this automatically generates certs in /etc/raddb/certs, which conflicts with this module. The alternative would be to allow bootstrap created certificates to exist, however I think we should be managing everything there, and not letting the OS generate its own data.

Does FreeRADIUS run in the default configuration without a certificate? Certificates are of course not required in all RADIUS use cases.

@djjudas21
Copy link
Owner

In the spirit of making it work out of the box (even if not usefully), would it be wise to include some logic that knows whether or not the distro systemd generates snake oil at startup? If the system generates it, we can thereafter manage what was generated, otherwise we generate it ourselves.

At least then it will always start up without having to do anything complex and won't make the module appear broken.

@yann-soubeyrand
Copy link
Author

I think I'm not sufficiently familiar with both this module and our setup (I'm just the guy reporting an issue which a colleague found and which I found a solution for on a bugzilla report :-P) to participate in the thinking about the best solution.

For the record, I deployed the following systemd override to solve our problem:

[Service]
ExecStartPre=
ExecStartPre=-/bin/chown -R radiusd.radiusd /var/run/radiusd
ExecStartPre=/usr/sbin/radiusd -C

@djjudas21
Copy link
Owner

Thanks @yann-soubeyrand, understood. We're just trying to understand the bug and discuss the best solution for all distros. I think we've got all the info we need from you now, until we manage to ship a fix. Hopefully in the meantime, other people will be able to find your workaround on here more easily than on bugzilla.

Cheers,
Jonathan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants