Why does connection to DSN fail when using Microsoft ODBC Driver for SQL Server on Red Hat Enterprise Linux?

Solution Unverified - Updated -

Issue

  • Connect using msodbcsql fails with error;
    Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : Driver's SQLAllocHandle on SQL_HANDLE_HENV failed.
$ sqlcmd -S <target_server> -D
Sqlcmd: Error: Microsoft ODBC Driver 13 for SQL Server : Driver's SQLAllocHandle on SQL_HANDLE_HENV failed.

$ isql -v <DSN> <user> <password>
[IM004][unixODBC][Driver Manager]Driver's SQLAllocHandle on SQL_HANDLE_HENV failed
[ISQL]ERROR: Could not SQLConnect

Environment

  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise linux 6
  • Microsoft ODBC Driver for SQL Server (msodbcsql)

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.