Project

General

Profile

Actions

Bug #3343

closed

(re)starting freeradius service throws "The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'"

Added by Matthias Güntert over 8 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Low
Assignee:
-
Category:
-
Target version:
-
Start date:
11/25/2013
Due date:
% Done:

0%

Estimated time:
Plus Target Version:
Affected Version:
Affected Plus Version:
Affected Architecture:

Description

This is related to freeRADIUS version 2.1.12_1/2.2.0 pkg v1.6.7_2 running on 2.1-RELEASE (i386)

Everytime i start or restart freeradius the following shows up in the logs

Nov 25 20:59:17 radiusd64163: Ready to process requests.
Nov 25 20:59:17 radiusd63859: Loaded virtual server <default>
Nov 25 20:59:14 php: /status_services.php: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Nov 25 20:59:13 radiusd68550: Exiting normally.
Nov 25 20:59:13 radiusd68550: Signalled to terminate

everything is working as expected though. maybe status_services.php is referencing the wrong file (this is an upgraded installation of pfsense)? please find bellow my startup files.

==================================================
$/root(7): cat /usr/local/etc/rc.d/radiusd.sh ==================================================
#!/bin/sh
  1. This file was automatically generated
  2. by the pfSense service handler.

rc_start() {
/usr/pbi/freeradius-i386/etc/rc.d/radiusd onestart
}

rc_stop() {
/usr/pbi/freeradius-i386/etc/rc.d/radiusd onestop
}

case $1 in
start)
rc_start
;;
stop)
rc_stop
;;
restart)
rc_stop
rc_start
;;
esac ==================================================

==================================================
/root(10): cat /usr/pbi/freeradius-i386/etc/rc.d/radiusd ==================================================
#!/bin/sh #
  1. $FreeBSD: ports/net/freeradius2/files/radiusd.in,v 1.5 2012/11/17 06:00:00 svnexp Exp $ #
  2. PROVIDE: radiusd
  3. REQUIRE: NETWORKING SERVERS slapd mysql postgresql
  4. KEYWORD: shutdown #
  5. Add the following lines to /etc/rc.conf to enable radiusd: #
  6. radiusd_enable="YES" #

. /etc/rc.subr

name=radiusd
rcvar=radiusd_enable
load_rc_config $name

command=/usr/pbi/freeradius-i386/sbin/radiusd

  1. In debug mode, radiusd doesn't create a pid file, so comment pidfile and
  2. let rc.subr use a process check on procname (which defaults to command).
    #pidfile=/var/run/radiusd/radiusd.pid

extra_commands="reload debug"
debug_cmd="radiusd_debug"

  1. The radiusd_config parameter is now obsolete. Instead, derive the
  2. configuration directory name from radiusd_flags if possible, otherwise
  3. default to /usr/pbi/freeradius-i386/etc/raddb
    required_dirs=`echo ${radiusd_flags} | sed Ene 's:.*\[^[:space:]d]*d[[:space:]]*([^[:space:]]+).*:\1:p'`
    required_dirs=${required_dirs:-"/usr/pbi/freeradius-i386/etc/raddb"}

required_files="${required_dirs}/radiusd.conf"

radiusd_enable=${radiusd_enable-"NO"}

command_args="&"

radiusd_debug() {
radiusd_flags="-X ${radiusd_flags}"
run_rc_command start
}

run_rc_command "$1" ==================================================

==================================================
/root(11): cat /usr/local/etc/rc.d/radiusd ==================================================
#!/bin/sh #
  1. $FreeBSD: ports/net/freeradius2/files/radiusd.sh.in,v 1.8 2012/01/14 08:56:14 dougb Exp $ #
  2. PROVIDE: radiusd
  3. REQUIRE: NETWORKING SERVERS slapd mysql postgresql
  4. KEYWORD: shutdown #
  5. Add the following lines to /etc/rc.conf to enable radiusd: #
  6. radiusd_enable="YES" #

. /etc/rc.subr

name=radiusd
rcvar=radiusd_enable
load_rc_config $name

command=/usr/local/sbin/radiusd

  1. In debug mode, radiusd doesn't create a pid file, so comment pidfile and
  2. let rc.subr use a process check on procname (which defaults to command).
    #pidfile=/var/run/radiusd/radiusd.pid

extra_commands="reload debug"
debug_cmd="radiusd_debug"

  1. The radiusd_config parameter is now obsolete. Instead, derive the
  2. configuration directory name from radiusd_flags if possible, otherwise
  3. default to /usr/local/etc/raddb
    required_dirs=`echo ${radiusd_flags} | sed Ene 's:.*\[^[:space:]d]*d[[:space:]]*([^[:space:]]+).*:\1:p'`
    required_dirs=${required_dirs:-"/usr/local/etc/raddb"}

required_files="${required_dirs}/radiusd.conf"

radiusd_enable=${radiusd_enable-"NO"}

command_args="&"

radiusd_debug() {
radiusd_flags="-X ${radiusd_flags}"
run_rc_command start
}

run_rc_command "$1" ==================================================

Actions #1

Updated by Salatiel Carvalho Farchi almost 7 years ago

I am also having the same problem.

Log File:

Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:42 radiusd46663: Exiting normally.
Oct 5 00:00:42 radiusd46663: Signalled to terminate
Oct 5 00:00:42 php-fpm2637: /rc.start_packages: Skipping STARTing packages process because previous/another instance is already running
Oct 5 00:00:41 radiusd46663: Ready to process requests.
Oct 5 00:00:41 radiusd43242: Loaded virtual server <default>
Oct 5 00:00:41 php-fpm23825: /rc.start_packages: The command '/usr/local/etc/rc.d/radiusd.sh stop' returned exit code '1', the output was 'radiusd not running?'
Oct 5 00:00:41 php-fpm23825: /rc.start_packages: Restarting/Starting all packages.
Oct 5 00:00:41 check_reload_status: Starting packages

Actions #2

Updated by Kill Bill almost 7 years ago

This is a complete non-issue. Restart = stop + start. If it's not running yet, then stop will "fail" ('radiusd not running?') and spit out the log noise. If you dislike noise, get it fixed in pfSense.

Actions #3

Updated by Adrian Lewis almost 7 years ago

I have this problem too.

Unfortunately this isn't a non-issue. In the scenario where pfsense panics or otherwise doesn't shutdown correctly, this issue stops freeradius from starting back up.

Obviously solving the root cause of why pfsense crashed in the first place is priority, but in our case it can randomly happen. Every other service recovers but radiusd.

Actions #4

Updated by Kill Bill almost 7 years ago

Adrian Lewis wrote:

this issue stops freeradius from starting back up.

No, it absolutely does not. You have different issue if you cannot start FreeRADIUS.

Actions #5

Updated by Pim Pish over 6 years ago

I have the same problem as Adrian Lewis. pfsense 2.2.6 amd64 radiusd keeps crashing down. My pfsense setup ran very well up until the point I recovered a configuration (got too excited with some configuration parameters and needed to recover a stable state).

Anyway, since this recovery radiusd keeps crashing sometimes a couple times a day, sometimes only every three days or something.
I have no idea where to look for the cause, since radiusd is generally working

Where to look for the cause of this issue? system.log doesn't tell me anything helpfull.
JFYI I had this issue some minor version earlier. My solution was to reinstall pfsense from scratch. Since I got tons of configuration parameters changed, this isn't a path I want to go again, cause it would mean like 2 days of work straight.

Thanks for every help. A conclusion to this issue might make pfsense a lot more stable, than it already is.

Actions #6

Updated by Jim Pingle over 6 years ago

  • Status changed from New to Closed

At this point unless it can be reproduced on the current version of FreeRADIUS on pfSense 2.3, it won't be addressed since it was likely fixed by an upgrade (base OS or FreeRADIUS) on 2.3.

Actions #7

Updated by Chris Becker almost 6 years ago

The problem is, that pfSense restarts the packages it self and also calls the restart method of freeradius itself.
So every time pfSense restarts packages (e.g. because of dyndns update) the radiusd gets restarted twice.
Because of that - in my setup - radiusd won't restart properly and therefore is not ready to process requests.

EDIT:

Log Output:

Nov 13 13:49:46 radiusd 58838 Exiting normally.
Nov 13 13:49:46 radiusd 58838 Signalled to terminate
Nov 13 13:49:45 radiusd 58838 Ready to process requests.
Nov 13 13:49:45 radiusd 57464 Loaded virtual server <default>
Nov 13 13:49:44 radiusd 25961 Exiting normally.
Nov 13 13:49:44 radiusd 25961 Signalled to terminate
Nov 13 13:49:44 php-fpm 53734 /rc.start_packages: Restarting/Starting all packages.

So the last state is "Exiting nomrmally" ... and radiusd isn't running anymore ...

stop / start / stop ... last stop command is too much

Actions

Also available in: Atom PDF