Queries to Windows MySQL servers from Linux Systems often fail unless the lower_case_table_names parameter is set to 0 in the my.ini file in the MySQL directory. Have a look at your my.ini file in the mysql directory, look under [mysqld] and if the setting is missing, insert it as shown below, then restart the MySQL service on Windows. Check this setting first, because on Linux, MySQL preserves the case of everything, the default on Windows is to convert tablenames to lower case, which causes Queries to fail from Linux machines to Windows based MySQL servers. Modify the my.ini file in the mysqld section to ensure case sensitivity is adhered to on Windows as follows: *[mysqld] lower_case_table_names = 0 . . . * Hope this helps. Cory Robson wrote:
The problem is with your sql server not with freeradius, I'm using the exact same sql statement on one of my machines.
MySQL runs fine with the original statement on a Linux derivative Seems an incompatibility issue.
-----Original Message----- From: freeradius-users-bounces+cory=cmi.net.au@lists.freeradius.org [mailto:freeradius-users-bounces+cory=cmi.net.au@lists.freeradius.org] On Behalf Of Hugh Messenger Sent: Tuesday, 8 May 2007 10:17 AM To: freeradius-users@lists.freeradius.org Subject: MySQL and postauth_query
Dear freeradius Alpha Geeks,
Am I loosing my mind or is there a bug in the postauth_query in the MySQL version of sql.conf?
I'm running freeradius 1.1.6 on RHEL4, and MySQL 5.0.37 on W2k. Don't ask.
Out-of-box, this postauth query ...
postauth_query = "INSERT into ${postauth_table} (id, user, pass, reply, date) values ('', '%{User-Name}', '%{User-Password:-Chap-Password}', '%{reply:Packet-Type}', NOW())"
.... fails with:
Incorrect integer value: '' for column 'id' at row 1
If I change this to remove the (auto incrementing) 'id' column ...
postauth_query = "INSERT into ${postauth_table} (user, pass, reply, date) values ('%{User-Name}', '%{User-Password:-Chap-Password}', '%{reply:Packet-Type}', NOW())"
.... it works.
-- hugh
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
__________ NOD32 2248 (20070507) Information __________
This message was checked by NOD32 antivirus system. http://www.eset.com
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
George Embrey CEO / Senior Systems Architect. Vmail Internet Services Pty Ltd. 318 Shoal Point Road Shoal Point QLD 4750 Australia