Hi to all,

  I've installad freeradius on a Debian box with Mysql DB.
After the upgrade from freeradius version 1.7 and freeradius 2.x I notice that sometimes, but everyday, the freeradius doesn't respond. I must do a /etc/init.d/freeradius restart

In my log:
Mon Oct 12 10:24:45 2009 : Info: rlm_sql (sql): There are no DB handles to use! skipped 0, tried to connect 0

The only modification that I have made to conf is:

with Freeradius 1.7
radius:/etc/freeradius# cat ../freeradius.orig/acct_users
DEFAULT         Acct-Status-Type == "Start"
Exec-Program = "/etc/freeradius/SCRIPT/userlogin.py %{User-Name}"
DEFAULT         Acct-Status-Type == "Stop"
Exec-Program = "/etc/freeradius/SCRIPT/userlogout.py %{User-Name"

on Freeradius 2.x I've modified the accounting conf file:

#
#  Accounting.  Log the accounting data
#
accounting {
              if (Acct-Status-Type == Start) {
update reply { Tmp-String-0 = "%{exec:/etc/freeradius/SCRIPT/userlogin.py %{User-Name}}" } }
               if (Acct-Status-Type == Stop) {
                       update reply {
Tmp-String-0 = "%{exec:/etc/freeradius/SCRIPT/userlogout.py %{User-Name}}"
                       }
              }

I need to launch a script with after login and logout.

Maybe this script cause some problems? It's a simple python script that update a field in db (online/offiline flag).
Can I substitute this external script with a query inside freeradius?
How can I create a custom (new) query and lunch it from the accounting section?

#
#  Accounting.  Log the accounting data
#
accounting {
              if (Acct-Status-Type == Start) {
update reply { LAUNCH MYQUERY HERE FOR A SPECIFIC USER } }
               if (Acct-Status-Type == Stop) {
                       update reply {
                           LAUNCH MYQUERY HERE FOR A SPECIFIC USER
                       }
              }



OR... may the problem is some slow query... but... how can I debug this? can someone suggest me a method?

Best regards.

--
Gianni Olivieri
SICE Telecomunicazioni
------------------------------------
Via Tazio Nuvolari, 53
55061 - Carraia (LU) - ITALY
------------------------------------------------
Tel. +39 0583 980787
Fax +39 0583 981495
www.sicetelecom.it
[email protected]
-----------------------------------------------
-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to