Question regarding Git config management

Alan DeKok aland at deployingradius.com
Wed May 27 17:25:52 CEST 2015


On May 27, 2015, at 11:15 AM, Sebastian Hagedorn <Hagedorn at uni-koeln.de> wrote:
> For our new Freeradius environment we will have a separate development server, one staging server and four production servers, but right now it's not in production yet. It took me a while, but I got things working in general. However, I'm pretty sure I found a bug in the post-receive hook:
> 
> https://github.com/alandekok/freeradius-server/blob/master/scripts/git/post-receive

  That's an old copy of the code.  I've fixed the link to point to the correct place.

> At least on a RHEL 6 system with Bash as /bin/sh, the syntax in line 109 causes an error:

  The script is fixed in the main FreeRADIUS git repository.

> When I create an error that's only detected at runtime, however, it does not seem to work.

  Yes, because the "check config" option checks if the configuration is correct.  It doesn't check a number of run-time problems.

> I changed the configuration so that two virtual servers were listening on the same port.

  I suppose that could be checked, too.  Feel free to send a patch. :)

> The "radmin -e hup" command did not throw an error. Consequently the commit was tagged as "stable". When I tried to manually restart Freeradius on the remote server, it didn't start anymore (as expected). At that point I wasn't even able to push a fix, because radmin doesn't work when the server isn't running, and so the post-receive hook reverted back to the "stable" version! I had to fix the error manually on the remote server to get things working again.

  That's a bit of a different issue.  If the server isn't running, then you should be able to push updates.  Please send a patch.

> I'm not sure what can be done about that, if anything, but at the very least I would like to have a better understanding of what class of error gets past a "radmin -e hup". Normally we would always test configuration changes locally on the staging server, so that errors like the one above shouldn't ever get pushed to a production system. But as you know, eventually everything that can go wrong will go wrong ...

  The check should really be without radmin.  Just stop the server and re-start it.

  Alan DeKok.




More information about the Freeradius-Users mailing list