• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1113
  • Last Modified:

Attempting to configure mysql odbc driver on redhat linux

Here are the mysql properties from ODBC.INI:

[mysqlmydb]
Driver=/usr/lib/libmyodbc3.so
Description=ODBC for MySQL
server=WIN-D2SJSG6EMDD
database=mydb
port=

Here are the mysql related contents of ODBCINST.INI:

(at the top)
[ODBC Drivers]
DataDirect 5.2 DB2 Wire Protocol=Installed
DataDirect 5.2 dBASEFile (*.dbf)=Installed
DataDirect 5.2 FoxPro 3.0 Database (*.dbc)=Installed
DataDirect 5.2 Informix Wire Protocol=Installed
DataDirect 5.2 Oracle Wire Protocol=Installed
DataDirect 5.2 Oracle=Installed
DataDirect 5.2 SQL Server Wire Protocol=Installed
DataDirect 5.2 Sybase Wire Protocol=Installed
DataDirect 5.2 TextFile (*.*)=Installed
MySQL=Installed


[MySQL]
Description    = ODBC for MySQL
Driver         = /usr/lib/libmyodbc3.so
Setup          = /usr/lib/libodbcmyS.so
FileUsage      = 1


My ODBCINI environment variable is set correctly since I have other odbc drivers that are working fine.

I verified that the files libmyodbc3.so and libodbcmyS.so are in the /usr/lib directory.

The error message I get in a third party reporting application is:
"Specified driver could not be loaded."
0
opike
Asked:
opike
  • 8
  • 6
1 Solution
 
arnoldCommented:
Doesn't the application you use have a native capability to access mysql either through the socket and requires an ODBC connection?
Have not used/configured ODBC in some time, but I think you have to include the username/password
the server to which you are connecting while making sure that the user you use has access rights to the mysql server from this location.

What is the application that you use that needs to use an ODBC type connection?
0
 
opikeAuthor Commented:
I'm 99% sure it is not an authentication (i.e. user/password) issue, since you get a specific message about a failed login when that happens. The driver is not being found or is otherwise not valid.

The application I'm trying to configure the odbc driver with is the oracle enterprise performance management suite a business intelligence reporting toolset that was formerly hyperion. It comes bundled with merant odbc drivers for many database types but unfortunately not mysql.
0
 
arnoldCommented:
Oracle now owns mysql, is there an option to access the mysql directly from the application?

Does your ODBC drive have an option to be configured with verbose logging?
Which version of mysql do you have running and which mysql ODBC driver did you get from mysql.com?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
opikeAuthor Commented:
I didn't see mysql as one of the default options. Since it is still relatively recent since Oracle acquired both Sun (mysql) and hyperion, it will probably take more time before everything is fully integrated.

I'll look into verbose logging.

The mysql ODBC driver I installed was mysql connector odbc 3.51.12-2.2.

The version of mysql server is 5.1.
0
 
arnoldCommented:
See if the below linked example works

presumably you are using the mysqlmydb as the DSN, but you are not including any username/password so not sure why you would expect an error dealing with login rejection.

http://dev.mysql.com/doc/refman/5.0/en/connector-odbc-configuration-dsn-unix.html

0
 
arnoldCommented:
ODBC.ini should use MySQL as the driver reference versus /usr/lib/libmyodbc3.so

[mysqlmydb]
Driver=MySQL
Description=ODBC for MySQL
server=WIN-D2SJSG6EMDD
database=mydb
USER=
Password=
port=
TraceFile=
Trace=Yes
 
also include
TraceFile=
Trace=Yes
 in the odbcinst.ini for MySQL but make sure to use different files.
0
 
opikeAuthor Commented:
The username and password don't have to be specified in the odbc.ini file. The oracle application prompts for them.

The Driver= field should point to the path of the actual driver file. Here's another ODBC entry in the same file for Oracle Native driver that works:

[repository]
QEWSD=40436
Driver=/opt2/Oracle/EPM/common/ODBC/Merant/5.2/lib/ARora22.so
Description=DataDirect 5.2 Oracle Wire Protocol
AlternateServers=
ApplicationUsingThreads=1
ArraySize=60000
CachedCursorLimit=32
CachedDescLimit=0
CatalogIncludesSynonyms=1
CatalogOptions=0
ConnectionRetryCount=0
ConnectionRetryDelay=3
DefaultLongDataBuffLen=1024
DescribeAtPrepare=0
EnableDescribeParam=0
EnableNcharSupport=0
EnableScrollableCursors=1
EnableStaticCursorsForLongData=0
EnableTimestampWithTimeZone=0
HostName=oracleepm
LoadBalancing=0
LocalTimeZoneOffset=
LockTimeOut=-1
#LogonID=
#Password=
PortNumber=1521
ProcedureRetResults=0
ReportCodePageConversionErrors=0
ReportRecycleBin=0
#ServerName=<none>
ServerType=0
ServiceName=
SID=XE
TimestampeEscapeMapping=0
TNSNamesFile=/usr/lib/oracle/xe/app/oracle/product/10.2.0/server/network/admin/tnsnames.ora
0
 
opikeAuthor Commented:
I added the trace file properties to odbc.ini but I think something about the environment is not set up correctly as the trace file is not even being generated. The odbc driver is not even being found by the application.

I'm trying to come up with a simple utilty that will let me test the connection outside of the oracle application. I may end up having to build a small C utility to do this.
0
 
arnoldCommented:
you can use odbcinst to test the DSN connection.
You can also use isql -v DSN username password
http://www.easysoft.com/developer/interfaces/odbc/linux.html#testing_dsns_unixodbc
0
 
opikeAuthor Commented:
That helped... I was able to connect with isql so that means that the environment is configured correctly. Still unable to connect with the oracle tools however (argh).
0
 
arnoldCommented:
within the oracle tools do you use a graphical or command line configuration?
Check whether the issue is with case sensitivity?
Does the tool configuration have an option to select Mysql ODBC connector driver from a list directly or must it go through unixODBC?
0
 
opikeAuthor Commented:
There are actually 2 tools I'm testing with, one uses a gui and the other is run from the command line so I can run it under the same environment as the isql test (that's the one I'm working on right now). You provide an ODBC DSN to the command line tool and then it uses the driver configuration as sepecified in odbc.ini and odbcinst.ini.

0
 
opikeAuthor Commented:
I'm going to say this issue is solved and that the oracle connectivity issue is a separate one...
0
 
opikeAuthor Commented:
Solved.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 8
  • 6
Tackle projects and never again get stuck behind a technical roadblock.
Join Now