Install MySQL ODBC on Solaris

The MySQL ODBC connector can be installed on Solaris 10 and 11 (sparc and x86).

To install the database/server, follow the MySQL instructions (or see above on Linux).

PMUL binaries are 32-bit. You must ensure a 32-bit version of ODBC is installed on Solaris 10 and 11.

  1. Install the MySQL package (output of the command is in the attached file):
  2. # pkgadd -d
    # /opt/csw/bin/pkgutil -U -u -y
    # /opt/csw/bin/pkgutil -y -i myodbc

Mysql-connector-odbc version 5.3.14 is not supported.

  1. In pb.settings set:
  2. eventdestinations authevt=odbc=MySQL
    odbcinidir  /opt/pbul/etc

    If you are using mysql-connector-odbc version 5.3.x with SSL enabled on MySQL server or mysql-connector-odbc version 8.0.x (with or without SSL), in pb.settings file, you need to configure the setting loadssllibs to yes.

    cat /etc/pb.settings | grep loadssllibs
    loadssllibs                         yes
  1. Configure Odbc.ini:
  2. [MySQL]
    Description = ODBC for MySQL
    Driver = MySQL
    server = <ip_of_MYSQL_host>
    port = 3306
    user = root
    password = <passwd>
    database = <database>
  1. Create /opt/pbul/etc/odbc.ini:
  2. [MySQL]
    Description  = ODBC for MySQL
    Driver = /opt/csw/lib/
    FileUsage = 1
    UsageCount = 3
    trace = no
    tracefile = stderr
  1. Set LD_LIBRARY_PATH to:
  2. LD_LIBRARY_PATH=/opt/csw/lib:/usr/lib:/lib:/usr/local/lib
  1. Restart pblighttpd.