Init startup script for radiusd (FreeRADIUS)

Discussion in 'Tomato Firmware' started by free2share, Feb 14, 2014.

  1. free2share

    free2share Addicted to LI Member

    Entware (
    Tomato Firmware 1.28.0000 MIPSR2-116 K26AC USB AIO-64K (RT-AC66U)
    freeradius2 - 2.2.0-1 - A flexible RADIUS server (version 2)

    Able to run radiusd manually from web Tools\System Commands or from SSH but not the Init Scripts. It works fine under the WAN Up. Is there another place where the radius service should be setup? Shutdown and firewall are both empty. It is set in Init or WAN Up but not at the same time.

    echo "LABEL=optware /opt ext3 defaults 1 1" >> /etc/fstab

    Administration/Scripts/WAN Up:

    References for installing FreeRADIUS v2 with Entware:

  2. jerrm

    jerrm Network Guru Member

    You're trying to run it before the USB drive is mounted.

    Google "tomatousb init sysup"
    free2share likes this.
  3. free2share

    free2share Addicted to LI Member

    Thank makes perfect sense. I looked at various sites and came up with trying the xx.autorun without any success.

    Placed the file at the root of /opt and set the chmod +x. Is this the correct way or is there a better way.

  4. jerrm

    jerrm Network Guru Member

    I don't really like .autorun scripts. Nothing necessarily wrong with them, but they are easy to forget about (especially if someone else comes along later and is wondering "how did X get started?"), so I prefer to have just about everything in init.

    I place what is safe to do early during boot at the top of init, wait for sysup, check for wan status, then call whatever else is needed.
  5. free2share

    free2share Addicted to LI Member

    jerrm, thanks for your help!

    If it helps anyone, this was the code to check sysup in the init script:
    while [ $A -gt 0 ] ; do
      A=$(( $A - 1 ))
      if [ -f /var/notice/sysup ] ; then  break; fi
      sleep 10
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice