Escuche. I want to write the Cisco-AVPair into the radacct.MySQL.Table.
Every time my sql-string ", '%{cisco-avpair}')" in the sql.conf, returns 
only the ip address and not the other stuff like ports and so on.

Here my modified SQL-String:

accounting_update_query_alt = "INSERT into ${acct_table1} \
        (AcctSessionId,AcctUniqueId,UserName, \
          Realm, NASIPAddress, NASPortId, NASPortType, \
          AcctStartTime, AcctSessionTime, AcctAuthentic, \
          ConnectInfo_start, AcctInputOctets, AcctOutputOctets, \
          CalledStationId, CallingStationId, ServiceType, FramedProtocol, \
          FramedIPAddress, AcctStartDelay, CISCO, CISCO2) \
values('%{Acct-Session-Id}', \
%{Acct-Unique-Session-Id}', '%{SQL-User-Name}', '%{Realm}',
'%{NAS-IP-Address}', \
'%{NAS-Port}', '%{NAS-Port-Type}', \
DATE_SUB('%S',INTERVAL (%{Acct-Session-Time:-0} + %{Acct-Delay-Time:-0})
SECOND), \
'%{Acct-Session-Time}', '%{Acct-Authentic}', '', '%{Acct-Input-Octets}', \
'%{Acct-Output-Octets}', '%{Called-Station-Id}', '%{Calling-Station-Id}', \
'%{Service-Type}', '%{Framed-Protocol}', '%{Framed-IP-Address}', '0', \
'%{Cisco-AVPair}', '%{Cisco-AVPair}')"
                                                                  
# Cisco-AVPair always returns ip:source-ip=3D10.10.10.23

Thanks, M. Wolf



-----Urspr�ngliche Nachricht-----
Von: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Im Auftrag von Mikhail
Stepanov
Gesendet: Dienstag, 13. Juli 2004 10:59
An: [EMAIL PROTECTED]
Betreff: RE: Cisco-AVPair store in MySQL4/freeradius1.0.0

>Ok, so far everything right. But how to modifying my sql-string?

>Like that, perhaps: ... , '%{cisco-avpair}')" ...? 

I can't understand what do you want to do. You needn't to modify any
sql-queries in freeradius. It returns all AV-pairs automatically.


Mikhail Stepanov.


- 
List info/subscribe/unsubscribe? See
http://www.freeradius.org/list/users.html




-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html

Reply via email to