[RADIATOR] Reducing the size of a variable
Hugh Irvine
hugh at open.com.au
Tue Feb 10 18:56:42 CST 2009
Hello Gilbert -
I agree with Claudio - it makes more sense to me to extend the field
in the database.
regards
Hugh
On 11 Feb 2009, at 08:15, Claudio Lapidus wrote:
> Hello Gilbert,
>
> Have you checked your table creation statement inside MSSQL? I'm by no
> means expert in that particular DB, but I'm absolutely sure it can
> handle strings MUCH longer than 10. You may want to define the field
> as VARCHAR(253), which is the absolute longest string you can get in
> RADIUS.
>
> Please bear in mind that Acct-Session-Id is arbitrary text that
> uniquely identifies a particular session. If you truncate it, you may
> end up mixing together data from different sessions.
>
> hope this helps,
> cl.
>
>
> On Tue, Feb 10, 2009 at 3:41 PM, Gilbert T. Gutierrez, Jr.
> <Gilbert.G at phoenixinternet.net> wrote:
>> I am getting the following errorTue Feb 10 10:02:48 2009: ERR: do
>> failed for
>> 'insert into Calls
>> (AcctDelayTime
>> ,AcctSessionId,AcctStatusType,CallDate,NASIdentifier,NASPort,U
>> serName) values (50,'1/0/0/1.69_0000040B',1,'Feb 10, 2009
>> 10:02','x.x.x.x',268501061,'familyinn')': [Microsoft][ODBC SQL Server
>> Driver][SQL Server]String or binary data would be truncated.
>> (SQL-22001)
>> [state was 22001 now 01000]
>>
>>
>> The system is having problems with the AcctSessionID field. The
>> MSSQL
>> database only allows for a string of 10 characters. How can I
>> truncate the
>> string before Radiator pushes it to the database? Below is my Realm
>> Definition.
>>
>> <Realm DEFAULT>
>> <AuthBy EMERALD>
>> DBSource dbi:ODBC:Platypus
>> DBUsername xxxx
>> DBAuth xxxx
>> AddATDefaults
>>
>> AccountingTable Calls
>> AcctColumnDef UserName,User-Name
>> AcctColumnDef CallDate,Timestamp,integer-date
>> AcctColumnDef AcctStatusType,Acct-Status-Type,integer
>> AcctColumnDef AcctDelayTime,Acct-Delay-Time,integer
>> AcctColumnDef AcctInputOctets,Acct-Input-
>> Octets,integer
>> AcctColumnDef AcctOutputOctets,Acct-Output-
>> Octets,integer
>> AcctColumnDef AcctSessionId,Acct-Session-Id
>> AcctColumnDef AcctSessionTime,Acct-Session-
>> Time,integer
>> AcctColumnDef
>> AcctTerminateCause,Acct-Terminate-Cause,integer
>> AcctColumnDef NASIdentifier,NAS-Identifier
>> AcctColumnDef NASIdentifier,NAS-IP-Address
>> AcctColumnDef NASPort,NAS-Port,integer
>> AcctColumnDef CallerID,Calling-Station-ID
>> </AuthBy>
>> <Log EMERALD>
>> DBSource dbi:ODBC:Platypus
>> DBUsername platypus
>> DBAuth big0mess
>> </Log>
>> </Realm>
>>
>>
>> Thank you,
>> Gilbert T. Gutierrez, Jr.
>>
>> _______________________________________________
>> radiator mailing list
>> radiator at open.com.au
>> http://www.open.com.au/mailman/listinfo/radiator
>>
>
> _______________________________________________
> radiator mailing list
> radiator at open.com.au
> http://www.open.com.au/mailman/listinfo/radiator
NB:
Have you read the reference manual ("doc/ref.html")?
Have you searched the mailing list archive (www.open.com.au/archives/radiator)?
Have you had a quick look on Google (www.google.com)?
Have you included a copy of your configuration file (no secrets),
together with a trace 4 debug showing what is happening?
Have you checked the RadiusExpert wiki:
http://www.open.com.au/wiki/index.php/Main_Page
--
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. Available on *NIX, *BSD, Windows, MacOS X.
Includes support for reliable RADIUS transport (RadSec),
and DIAMETER translation agent.
-
Nets: internetwork inventory and management - graphical, extensible,
flexible with hardware, software, platform and database independence.
-
CATool: Private Certificate Authority for Unix and Unix-like systems.
More information about the radiator
mailing list