How to Install SQL Server ODBC Driver on Linux
Overview
HVR AMI does not work out of the box because the SQL Server ODBC driver is not bundled with this package due to licensing restrictions. The Unix ODBC 2.3.1 driver is required to communicate with the SQL Server database. Unfortunately, the installation cannot be found in the Amazon Linux package repository, and therefore it cannot be installed with a simple sudo yum install
. Instead, it has to be downloaded and installed by you.
Steps
Here are the steps to download and install the driver on your AWS HVR hub.
Create a temporary folder on your hub machine, for example in the
/tmp
folder:$ mkdir /tmp/odbc $ cd /tmp/odbc
Download the Unix ODBC and SQL Server ODBC packages:
$ wget http://mirror.centos.org/centos/7/os/x86\_64/Packages/unixODBC-2.3.1-14.el7.x86\_64.rpm $ wget https://packages.microsoft.com/rhel/7/prod/msodbcsql17-17.3.1.1-1.x86\_64.rpm
Install both packages:
$ sudo rpm -i unixODBC-2.3.1-14.el7.x86\_64.rpm $ sudo rpm -i msodbcsql17-17.3.1.1-1.x86\_64.rpm
Create a symbolic link from libodbc.so.2 library to libodbc.so.1
$ cd /usr/lib64 $ sudo ln -s libodbc.so.2 libodbc.so.1
Make sure you add your hub's private IP address to the RDS instance's security group.