Get some of the logs from your existing radius
and use radclient to send them. Worked
for me. 

Goes like this.

Take the ordinary flat file log from your current
radius server, call this 'logx'
This should be of format
DATESTAMP
   series of value pairs
(blank line)
DATESTAMP 
   series of value pairs
(blank line)
DATESTAMP
   series of value pairs
etc, etc, etc

Now you need to remove the datestamp
You can do this with a perl regular expresion.
If the log was from 7th August do
#perl -p -i -e 's/^\s*Aug  7\s*$//g' logx

Now your log file is just a series of value pairs
with line seperators between packets

This is format radclient likes
so now just do (on one line)

(this if you are in bin with radclient)
#./radclient -f logx -d ../etc/raddb your_ip:1813 acct your_secret_key

and that'll send your data.

I got the occasion error from radclient because 
freeradius dictionaries and previous radius servers
dictionaries varied so radclient couldnt work out
what to send

errors like this

radclient:Unknown value Remote-End-Hung-Up for attribute 
�-x@�-x@isconnect-Cause

can be cured by doing global searc/replace on logx
and changing your old name for a name in freeradius's 
dictionary.

Good luck

Rob

On Tuesday 07 August 2001 11:22, you wrote:
> On Tuesday 07 August 2001 04:44 am, you wrote:
> > so i've been moving to freeradius on a testing box and sql-izing it and
> > all that jazz.. everything seems to be working fine.. i can test
> > authentication with radclient .. but what I haven't figured out how to do
> > is to use radclient or some other program to populate my accounting part
> > of the database.  And unfortunately I don't have a spare termserver
> > around to work with.  Any suggestions.. Thanks
> >
> > -jason
>
>  First I would assume that a real live NAS has to send accounting data:)
>
> I had problems with the SQL Insert queries (sql.conf) they were related to
> the time fields. The script to polulate the db had hard coded time stamps
> and did not like my hyperarc output .  I ran the server in debug mode and
> dumped to sqltrace.sql and saw the errors. Then ran the queries at a psql
> command prompt and duplicated the problem. Removing the inserts to the time
> related fields got it working, it (mine) uses the pcs time stamp not the
> NAS.
>
>  If you wish I can send you the sql.conf directly.
>
>  If what I did to make this work is not correct then someone please let me
> know.
>
> Scott
>
> -
> 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