(RADIATOR) radiator dies w/sql

Tony Bunce tonyb at go-concepts.com
Mon Aug 19 23:52:26 CDT 2002


We have been running radiator for a long time now and have not had any problems, but have one issue
 
I have the conf file such that if our AuthBy SQL ignores the request then it goes to AuthBy File.  This way if the sql server dies users can still authenticate on the flat file
 
We have never had problems with the sql server (MySql) but I was trying to test the authby file by stopping the sql server.  Radiator looses it's connection then dies w/o logging anything
 
Here is conf:
 
#Foreground
#LogStdout
LogDir          /var/log/radius
DbDir           /etc/radiator
DictionaryFile %D/dictionary
 
 
 
# it to 4 or 5 for debugging, or use the -trace flag to radiusd
Trace   4
 
#AuthPort 2900
#AcctPort 2901
 
#Lower case
RewriteUsername   tr/A-Z/a-z/
 
#Remove Spaces
RewriteUsername          s/\s+//g
 
 
#DateFormat '%Y-%M-%d %T'
 
<ClientListSQL>
                DBSource DBI:Sybase:database=bill2;server=GO19
                DBUsername <CUT>
                DBAuth <CUT>
                GetClientQuery select NASIDENTIFIER,SECRET,IGNOREACCTSIGNATURE,DUPINTERVAL,DEFAULTREALM,NASTYPE,SNMPCOMMUNITY,LIVINGSTONOFFS,LIVINGSTONHOLE,FRAMEDGROUPBASEADDRESS,FRAMEDGROUPMAXPORTSPERCLASSC,REWRITEUSERNAME,NOIGNOREDUPLICATES,PREHANDLERHOOK,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,FLAGS from NASClients
                #UseOldAscendPasswords
</ClientListSQL>
 
 
<SessionDatabase SQL>
        DBSource dbi:mysql:radius:207.40.xxx.xx
        DBUsername <CUT>
        DBAuth  <CUT>
</SessionDatabase>
 
<Log SQL>
        DBSource dbi:mysql:radius:207.40.xxx.xx
        DBUsername <CUT>
        DBAuth  <CUT>
 
        Table RADLOG
</Log>
 
<AuthLog SQL>
        Identifier AuthLogMySql
        DBSource dbi:mysql:radius:207.40.xxx.xx
        DBUsername <CUT>
        DBAuth  <CUT>
        Table AuthLog 
        FailureQuery INSERT into AuthLog (SeverityLevel, Username, SubmitedPassword, Reason, Date) VALUES (%0, '%U','%P',%1, '%Y-%m-%d %H:%M:%S')
        LogFailure 1
</AuthLog>
 
 
 
<Handler Request-Type=Access-Request>
        RewriteUsername s/^([^@]+).*/$1/
        #PasswordLogFileName %L/password.log
 
        <AuthBy SQL>
                Timeout 10
                NoDefaultIfFound
                DefaultSimultaneousUse 1
                CaseInsensitivePasswords
                RejectEmptyPassword
 
                Identifier GOCsql
                DefaultReply Ascend-Shared-Profile-Enable=0,Service-Type=Framed-User,Framed-Protocol=PPP,Framed-Routing=None,Ascend-Base-Channel-Count=1,Ascend-Minimum-Channels=1,Ascend-Maximum-Channels=1,Ascend-Assign-IP-Pool=1,Ascend-Multicast-Client=Multicast-Yes
 
                DBSource DBI:Sybase:database=bill2;server=GO19
                DBUsername <CUT>
                DBAuth <CUT>
 
                AuthSelect AuthSelect '%n'
 
                AuthColumnDef 0, User-Password, check
                AuthColumnDef 1, Framed-IP-Address, reply
                AuthColumnDef 2, Framed-Netmask, reply
                #AuthColumnDef 3, Ascend-Maximum-Channels, reply
                AuthColumnDef 3, GENERIC, reply
                AuthColumnDef 4, GENERIC, check
 
 
                #AddToReplyIfNotExist User-Service=Framed-User,Framed-Protocol=PPP,Framed-Routing=None,Ascend-Base-Channel-Count=1,Ascend-Minimum-Channels=1,Ascend-Maximum-Channels=1,Ascend-Assign-IP-Pool=1,Ascend-Multicast-Client=Multicast-Yes
                AddToReplyIfNotExist Framed-Routing=None,Service-Type=Framed-User,Framed-Protocol=PPP
        </AuthBy SQL>
        <AuthBy FILE>
                NoDefaultIfFound
                DefaultSimultaneousUse 2
        </AuthBy FILE>
        AuthLog AuthLogMySql
</Handler>
 
 
<Handler Request-Type=Accounting-Request>
        <AuthBy SQL>
                DateFormat %Y-%m-%d %T
                Identifier MySQL
                DBSource dbi:mysql:radius:207.40.xxx.xx
                DBUsername <CUT>
                DBAuth  <CUT> 
 
 
                AuthSelect              
 
                AccountingTable Accounting%{Acct-Status-Type}
                #AccountingTable Accounting
                AcctColumnDef   Username,%U,formatted
                AcctColumnDef   TIME_STAMP,Timestamp,integer
                AcctColumnDef   AcctStatusType,Acct-Status-Type
                AcctColumnDef   SessionID,Acct-Session-Id
                AcctColumnDef   SessionTime,Acct-Session-Time,integer
                AcctColumnDef   DisconnectCause,Ascend-Disconnect-Cause,integer
                AcctColumnDef   ConnectProgress,Ascend-Connect-Progress,integer
                AcctColumnDef   NASIdentifier,NAS-Identifier
                AcctColumnDef   NASPort,NAS-Port,integer
                AcctColumnDef   ModemPort,Ascend-Modem-PortNo,integer
                AcctColumnDef   ModemSlot,Ascend-Modem-SlotNo,integer
                AcctColumnDef   IPAddress,Framed-IP-Address
                AcctColumnDef   XmitRate,Ascend-Xmit-Rate
                AcctColumnDef   DataRate,Ascend-Data-Rate
                AcctColumnDef   Protocol,Framed-Protocol
                AcctColumnDef   CallerID,Caller-Id
                AcctColumnDef   Date,Timestamp,integer-date
        </AuthBy SQL>
</Handler>
 
And The Error Log:
Wed Aug 14 13:39:25 2002: DEBUG: Packet dump:
*** Received from 207.40.122.227 port 1026 ....
Code:       Access-Request  
Identifier: 242
Authentic:  q<183>ms^o<25>OK<224>#<173>u;(2
Attributes:
        User-Name = "test"
        User-Password = "<CUT>"
        NAS-IP-Address = 207.40.122.227
        NAS-Port = 20312    
        NAS-Port-Type = Async
        Service-Type = Framed-User
        Framed-Protocol = PPP
        State = ""
        Acct-Session-Id = "352874968"
        Ascend-Data-Rate = 28800
        Ascend-Xmit-Rate = 31200
 
Wed Aug 14 13:39:25 2002: DEBUG: Rewrote user name to test
Wed Aug 14 13:39:25 2002: DEBUG: Rewrote user name to test
Wed Aug 14 13:39:25 2002: DEBUG: Handling request with Handler 'Request-Type=Access-Request'
Wed Aug 14 13:39:25 2002: DEBUG: Rewrote user name to test
Wed Aug 14 13:39:25 2002: DEBUG:  Deleting session for test, 207.40.122.227, 20312
Wed Aug 14 13:39:25 2002: DEBUG: do query is: delete from RADONLINE where NASIDENTIFIER='207.40.122.227' and NASPORT=020312
 
Wed Aug 14 13:39:25 2002: ERR: do failed for 'delete from RADONLINE where NASIDENTIFIER='207.40.122.227' and NASPORT=020312': Lost  connection to MySQL server during query
#THIS IS WHERE I RESTARTED IT b/c IT DIED
Wed Aug 14 13:40:44 2002: DEBUG: Adding Clients from SQL database
Wed Aug 14 13:40:44 2002: DEBUG: Query is: select NASIDENTIFIER,SECRET,IGNOREACCTSIGNATURE,DUPINTERVAL,DEFAULTREALM,NASTYPE,SNMPCOM
 
Wed Aug 14 13:40:44 2002: DEBUG: Reading users file /etc/radiator/users
Wed Aug 14 13:40:44 2002: INFO: Server started: Radiator 3.0 on rad1.go-concepts.com
 
Thanks for the help
 
 
Thanks,
Tony B, CCNA, Network+
Systems Administration
GO Concepts, Inc. / www.go-concepts.com
Are you on the GO yet?
What about those you know, are they on the GO?
513.934.2800
1.888.ON.GO.YET
 
===
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.


More information about the radiator mailing list