如何在 Linux 中为 ODBC 创建 DSN?
我正在研究一个 Linux 应用程序,据说该应用程序使用 DSN 连接到 SQL Server。 连接停止工作,我找不到正在使用的凭据(我只知道 DSN 的名称)。
我熟悉 Windows 中的 DSN,但在 Linux 中它们是如何创建以及存储在哪里?
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).
I am familiar with DSNs in Windows, but how are they created and where are they stored in Linux?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
对于 unixODBC,DSN 在
/usr/local/etc/odbc.ini
中列出。 已安装的 ODBC 驱动程序将在/usr/local/etc/odbcinst.ini
中列出。尝试:
For unixODBC, DSNs are listed in
/usr/local/etc/odbc.ini
. Installed ODBC drivers will be listed in/usr/local/etc/odbcinst.ini
.Try:
只需查找 odbc.ini 文件即可。 默认情况下它应该位于 /etc 下,但我想它可能因一种 Linux 风格而异。
这是一个通用指南Linux/Unix。
希望这可以帮助。
Simply look for your odbc.ini file. By default it should be under /etc, but I guess it can differ from one Linux flavour to another.
This is a generalized guide for Linux/Unix.
Hope this helps.