On Jul 20, 2016, at 9:55 AM, Wegener, Norbert <norbert.wegener@atos.net> wrote:
I have my users in a local mysql database and want to send logs to a central mysql database via sql-relay.
You should use the rlm_sql_null driver to log SQL queries to disk. The queries will be created and written to disk, without checking any local database.
I get a server error: ... (0) sqldef: --> INSERT INTO radpostauth (username, pass, reply, authdate, nasname, ... (0) sqldef: ERROR: rlm_sql_mysql: ERROR 1054 (Unknown column 'nasipaddress' in 'field list'): 42S22 (0) sqldef: SQL query returned: server error
That only happens because you're writing to *both* a local SQL database, and also to disk. If you configure one SQL module to write to a local DB, without logging, it will work. Then, configure another SQL module using the rlm_sql_null driver. Have it log to disk, and it won't write to any local DB. Alan DeKok.