SYMPTOM
Detailed instructions on how to download and install MySQL ODBC driver and how to configure odbc.ini file in Linux.
ACTION
Appropriate ODBC driver can be downloaded from official MySQL website:
https://dev.mysql.com/downloads/connector/odbc/
To install or upgrade Connector/ODBC from an RPM distribution on Linux, download the RPM distribution of the latest version of Connector/ODBC and follow the instructions below. Use su root to become root, and then install the RPM file.
If you are installing for the first time:
shell> su root
shell> rpm -ivh mysql-connector-odbc-5.2.2.i386.rpm
In case if a previous driver version is installed on the server, upgrade it using the following commands:
shell> su root
shell> rpm -Uvh mysql-connector-odbc-5.2.2.i386.rpm
If there is any dependency error for MySQL client library, libmysqlclient, simply ignore it by supplying the --nodeps option, and then make sure the MySQL client shared library is in the path or set through LD_LIBRARY_PATH.
This installs the driver libraries and related documents to /usr/local/lib and /usr/share/doc/MyODBC, respectively.
Reference: https://dev.mysql.com/doc/connector-odbc/en/connector-odbc-installation-binary-unix-rpm.html
After the MySQL ODBC driver is installed, please check the installation path and name of the driver and then, open your odbc.ini file and check the following strings:
Driver=/usr/lib/libmyodbc5w.so
Description=MySQL ODBC 5.x Driver