Problems using freeradius+postgresql

Daniel Bojczuk daniel at cirp.usp.br
Fri Jun 29 20:38:44 CEST 2007


Hi,
I'm using Freeradius 1.1.6 with PostgreSQL 8.1.

When I try to do #radtest joao senhasecreta 127.0.0.1:1812 0 testing123

Te radiusd (in debug mode) returns:

#rad_recv: Access-Request packet from host 127.0.0.1:32779, id=220, length=56
#        User-Name = "joao"
#        User-Password = "senhasecreta"
#        NAS-IP-Address = 255.255.255.255
#        NAS-Port = 0
#  Processing the authorize section of radiusd.conf
#modcall: entering group authorize for request 0
#  modcall[authorize]: module "preprocess" returns ok for request 0
#    rlm_realm: No '@' in User-Name = "joao", looking up realm NULL
#   rlm_realm: No such realm "NULL"
#  modcall[authorize]: module "suffix" returns noop for request 0
#radius_xlat:  'joao'
#rlm_sql (sql): sql_set_user escaped user --> 'joao'
#radius_xlat:  'SELECT id, UserName, Attribute, Value, Op ??FROM radcheck
??WHERE Username = 'joao' ??ORDER BY id'
#rlm_sql (sql): Reserving sql socket id: 4
#rlm_sql_postgresql: query: SELECT id, UserName, Attribute, Value, Op
??FROM radcheck ??WHERE Username = 'joao' ? ORDER BY id
#rlm_sql_postgresql: Status: PGRES_FATAL_ERROR
#rlm_sql_postgresql: affected rows =
#rlm_sql_postgresql: Postgresql check_error: PGRES_FATAL_ERROR, returning
SQL_DOWN
#rlm_sql (sql): Attempting to connect rlm_sql_postgresql #4
#rlm_sql (sql): Connected new DB handle, #4
#rlm_sql_postgresql: query: SELECT id, UserName, Attribute, Value, Op
??FROM radcheck ??WHERE Username = 'joao' ??ORDER BY id
#rlm_sql_postgresql: Status: PGRES_FATAL_ERROR
#rlm_sql_postgresql: affected rows =
#rlm_sql_postgresql: Postgresql check_error: PGRES_FATAL_ERROR, returning
SQL_DOWN
#rlm_sql (sql): failed after re-connect
#rlm_sql_getvpdata: database query error
#rlm_sql (sql): SQL query error; rejecting user
#rlm_sql (sql): Released sql socket id: 4
#  modcall[authorize]: module "sql" returns fail for request 0
#modcall: leaving group authorize (returns fail) for request 0
#Finished request 0

When I saw the "??" int the queries i changed te query in postgresql.conf
putting al the query on the same line (deleting the "/")... but it doesn't
work.

I'm new on using freeradius, I don't know what I can do.

Thank you..

Daniel Bojczuk





More information about the Freeradius-Users mailing list