I am digging around in a Linux application that supposedly uses DSNs to connet to SQL Server. The connection stopped working and I can't find the credentials that are being used (all I know is the DSN's name).
我正在挖掘一个Linux应用程序,该应用程序应该使用DSN来连接到SQL Server。连接停止工作,我找不到正在使用的凭据(我所知道的只是DSN的名称)。
I am familiar with DSNs in Windows, but how are they created and where are they stored in Linux?
我熟悉Windows中的DSN,但是它们是如何创建的以及它们存储在Linux中的哪个位置?
2 个解决方案
#1
10
Simply look for your odbc.ini file. Usually it should be under /etc, but I guess it can differ from one Linux flavour to another.
只需查找您的odbc.ini文件即可。通常它应该在/ etc下,但我想它可以从一种Linux风味到另一种不同。
Some information on how it is done in Ubuntu, and this is a generalized guide for Linux/Unix.
有关如何在Ubuntu中完成的一些信息,这是Linux / Unix的通用指南。
Hope this helps.
希望这可以帮助。
#2
9
For unixODBC, DSNs are listed in /usr/local/etc/odbc.ini
. Installed ODBC drivers will be listed in /usr/local/etc/odbcinst.ini
.
对于unixODBC,DSN列在/usr/local/etc/odbc.ini中。已安装的ODBC驱动程序将在/usr/local/etc/odbcinst.ini中列出。
Try:
尝试:
usr$ find . -iname 'odbc*.ini'
#1
10
Simply look for your odbc.ini file. Usually it should be under /etc, but I guess it can differ from one Linux flavour to another.
只需查找您的odbc.ini文件即可。通常它应该在/ etc下,但我想它可以从一种Linux风味到另一种不同。
Some information on how it is done in Ubuntu, and this is a generalized guide for Linux/Unix.
有关如何在Ubuntu中完成的一些信息,这是Linux / Unix的通用指南。
Hope this helps.
希望这可以帮助。
#2
9
For unixODBC, DSNs are listed in /usr/local/etc/odbc.ini
. Installed ODBC drivers will be listed in /usr/local/etc/odbcinst.ini
.
对于unixODBC,DSN列在/usr/local/etc/odbc.ini中。已安装的ODBC驱动程序将在/usr/local/etc/odbcinst.ini中列出。
Try:
尝试:
usr$ find . -iname 'odbc*.ini'