Forum Discussion

Timothy_Quinn's avatar
Timothy_Quinn
Copper Contributor
Apr 30, 2023

ODBC Driver Ubuntu 22.04 - libodbc.so.2 Issue

On my main development desktop which is running a fully updated Ubuntu 22.04, I just recently hit an issue with the ODBC drivers related to libodbc.so.2. When running `sqlcmd` or using python, I got the following error: `error while loading shared libraries: libodbc.so.2: cannot open shared object file: No such file or directory`

 

I tried uninstalling and re-installing following the instructions for both v17 and v18 but with no luck.

 

The way I resolved this was by installing libodbc2: `sudo apt install libodbc2`

 

For Microsoft devs, maybe add a dependency for libodbc2.

 

1 Reply

  • Timothy_Quinn's avatar
    Timothy_Quinn
    Copper Contributor
    FYI - I tried to reproduce this on a clean install of Ubuntu 22.04 but was not able to reproduce the issue so there seems to be something with my main system that triggered this bug. My main system is an upgraded 20.04 that was initially installed a couple years back.

Resources