The Hortonworks Community Connection is now live. A completely rebuilt Q&A forum, Knowledge Base, Code Hub and more, backed by the experts in the industry.

You will be redirected here in 10 seconds. If your are not redirected, click here to visit the new site.

The legacy Hortonworks Forum is now closed. You can view a read-only version of the former site by clicking here. The site will be taken offline on January 31,2016

Hortonworks Sandbox Forum

Tutorial 11: Configuring Mac ODBC

  • #46299
    Philip Topham

    I’m stuck, and cannot get the iODBC driver to work. Can anyone help?

    Current setup: MAC OSX 10.9.1
    Sandbox: 2.0
    iODBC: 3.52.7
    Excel Mac: 2011

    When I test with Excel I get [iODBC][Driver Manager]Specified driver could not be loaded. — the iODBC forum says to check file paths and configurations. I’ve done so but still doesn’t seem to work. What have I overlooked.
    Here are my detailed steps

    1) The ENV variable is “DYLD\_LIBRARY\_PATH=/usr/lib/hive/lib/native/universal” has been added permanently.
    a) I verified that the path exists
    user$ ls /usr/lib/hive/lib/native/universal
    total 170968
    drwx---r-x 8 root wheel 272 Jan 2 18:20 ./
    drwx---r-x 4 root wheel 136 Aug 8 12:17 ../
    -rwxr-xr-x 1 root wheel 544 Aug 8 12:17 SimbaHiveODBC.did*
    -rwxr-xr-x 1 root wheel 3309240 Aug 8 12:17 libcrypto.1.0.0.dylib*
    lrwxr-xr-x 1 root wheel 21 Jan 2 18:19 libcrypto.dylib@ -> libcrypto.1.0.0.dylib
    -rwxr-xr-x 1 root wheel 83439736 Aug 8 12:17 libhortonworkshiveodbc.dylib*
    -rwxr-xr-x 1 root wheel 769176 Aug 8 12:17 libssl.1.0.0.dylib*
    lrwxr-xr-x 1 root wheel 18 Jan 2 18:20 libssl.dylib@ -> libssl.1.0.0.dylib

    2) Both ODBC ini files are in my home directory with READ permission for all

    user$ ls ~/.odbc*ini
    -rw-r--r--@ 1 user staff 1024 Jan 3 09:28 /Users/user/.odbc.ini
    -rw-r--r-- 1 user staff 198 Aug 8 12:17 /Users/user/.odbcinst.ini

    3) The default sandbox user is ‘hue’ , which I checked by going to “” and looking at the useradmin tab information.

    4) For ODBC.INI, the HOST was updated to (i.e localhost) as was the host fully qualified domain name HS2HostFQDN

    #HS2HostFQDN=[Hive Server 2 Host FQDN]
    HS2KrbServiceName=[Hive Server 2 SASL service name]

    5) FOR ODBCINST.INI, that was not change but I did verify file paths

    user$ ls /usr/lib/hive/lib/native/universal/libhortonworks*
    -rwxr-xr-x 1 root wheel 83439736 Aug 8 12:17 /usr/lib/hive/lib/native/universal/libhortonworkshiveodbc.dylib*

    cat ~/.odbcinst.ini
    [ODBC Drivers]
    Hortonworks Hive ODBC Driver=Installed

    [Hortonworks Hive ODBC Driver]
    Description=Hortonworks Hive ODBC Driver

  • Author
  • #46382
    Kyle Porter

    Hi Philip,

    My name is Kyle, and I work for Simba Technologies which develops the underlying ODBC driver that you are using. I may be able to help you resolve the issue you’re facing, as we’ve seen a few similar issues.

    Would you be able to do the following:

    1) Set the following environment variables
    a. ODBCINI = /usr/lib/hive/lib/native/hiveodbc/Setup/odbc.ini
    b. ODBCINSTINI = /usr/lib/hive/lib/native/hiveodbc/Setup/odbcinst.ini
    c. SIMBAINI = /usr/lib/hive/lib/native/hiveodbc/Setup/hortonworks.hiveodbc.ini

    This is because, in our testing, we noticed that the ini files were not being picked up by the iodbctest program even though they were in the home directory

    2) Starting up Excel:
    You can do either of the following options to launch Excel:

    a. Launch Excel from command line
    i. Set the environment variable DYLD_LIBRARY_PATH =/usr/lib/hive/lib/native/universal/
    ii. Go to “/Applications/Microsoft Office 2011/Microsoft” and launch Excel in command line
    b. Set launchctl from the command line
    i. launchctl setenv DYLD_LIBRARY_PATH /usr/lib/hive/lib/native/universal/
    ii. Open Excel as usual from the launcher.


    Philip Topham

    That suggesting moved me forward but still no complete resolution.
    Ensuring “launchctl setenv DYLD_LIBRARY_PATH /usr/lib/hive/lib/native/universal/” seems to be essential even though the same information is in the /etc/launched.conf

    After making those changes, I started receiving the [Hortonworks][Hardy] (34) Error from Hive: connect() Connection refused.

    Through a lot of futzing, I discovered that the Oracle VM Virtual Box, maps PORT 10000 to PORT 2200
    — You can see what ports the Sandbox 2.0 is using on the Oracle Virtual Box, by going to
    –> Oracle VM Virtual Box Manager
    –> Selecting the NETWORK icon
    –> Selecting “Port Forwarding”

    The Column HOST PORT reforest to my MAC (listed at 2200)
    The Column GUEST PORT refers to the SANDBOX (listed as 10000)

    NOTE The Configure Button in the iODBC Data Source Chooser (accessed from Execl–> Get External Data) doesn’t allow the ODBC.INI file to be updated, even though the file’s permissions are set to RW…RW..RW…

    I hope this saves someone else some troubleshooting time.

    Cheers Philip.

    Kyle Porter

    Hi Philip,

    Just to be clear, at this point you’re receiving the Connection refused message and haven’t managed to resolve your issue, correct?


    Philip Topham

    Sorry, I wasn’t clear. I am connecting now.

    The basic issues where, I had to:
    1) add all the ENV variables
    2) RERUN the following command everytime, even though this should auto launch on system startup —-> launchctl setenv DYLD_LIBRARY_PATH /usr/lib/hive/lib/native/universal/
    3) Change the hive server port in the INI file to 2200, because the default Sandbox 2.0 server forwards port 2200 to port 10000.

    Kyle Porter

    Fantastic, glad to hear you’ve gotten everything working.

The topic ‘Tutorial 11: Configuring Mac ODBC’ is closed to new replies.

Support from the Experts

A HDP Support Subscription connects you experts with deep experience running Apache Hadoop in production, at-scale on the most demanding workloads.

Enterprise Support »

Become HDP Certified

Real world training designed by the core architects of Hadoop. Scenario-based training courses are available in-classroom or online from anywhere in the world

Training »

Hortonworks Data Platform
The Hortonworks Data Platform is a 100% open source distribution of Apache Hadoop that is truly enterprise grade having been built, tested and hardened with enterprise rigor.
Get started with Sandbox
Hortonworks Sandbox is a self-contained virtual machine with Apache Hadoop pre-configured alongside a set of hands-on, step-by-step Hadoop tutorials.
Modern Data Architecture
Tackle the challenges of big data. Hadoop integrates with existing EDW, RDBMS and MPP systems to deliver lower cost, higher capacity infrastructure.