[unixODBC-support] Unable to connect: Adaptive Server is unavailable or does not exist

Funny,Solomon Solomon.Funny at fhlbny.com
Thu Mar 17 19:58:39 GMT 2016


My company has installed free TDS driver along with unixODBC.

I am receiving the following error when trying to test connectivity from a Linux server to a Windows SQL Server Named Instance:

When issuing the command,  tsql -S TITAN -U funnys , to test connectivity.  The followwing error is received:

locale is "en_US.UTF-8"
locale charset is "UTF-8"
using default charset "UTF-8"
Error 20009 (severity 9):
        Unable to connect: Adaptive Server is unavailable or does not exist
        OS error 111, "Connection refused"
There was a problem connecting to the server

When issuing the command,  isql -v TITAN funnys , to test connectivity.  The flowing error is received:

[S1000][unixODBC][FreeTDS][SQL Server]Unable to connect to data source
[08S01][unixODBC][FreeTDS][SQL Server]Unable to connect: Adaptive Server is unavailable or does not exist
[ISQL]ERROR: Could not SQLConnect

I can ping the target server (NTS-ENTDBD1), which contains the SQL Server Database successfully:

ping NTS-ENTDBD1
PING NTS-ENTDBD1.fhlbny-ads (10.2.201.41) 56(84) bytes of data.
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=1 ttl=128 time=0.371 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=2 ttl=128 time=0.158 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=3 ttl=128 time=0.187 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=4 ttl=128 time=0.157 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=5 ttl=128 time=0.212 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=6 ttl=128 time=0.195 ms
64 bytes from nts-entdbd1.fhlbny-ads (10.2.201.41): icmp_seq=7 ttl=128 time=0.179 ms

I cannot telnet to the target server (NTS-ENTDBD1), as per Corporate Security Standards, the command is not allowed

I have configured the freetds.conf, odbcinst.ini, and odbc.ini as follows:

freetds.conf
# A typical Microsoft server
[TITAN]
        host = 10.2.201.41   ===> NTS-ENTDBD1 (Server hosting the SQL Server Instance)
       port = 1433
        tds_version = 7.1
        client charset = UTF-8

odbcinst.ini
[FreeTDS]
Description = Microsoft SQL Server Access with FreeTDS
Driver = /usr/lib64/libtdsodbc.so.0
Setup =  /usr/lib64/libtdsodbc.so.0.0.0
FileUsage = 1

odbc.ini files
[TITAN]
Driver = FreeTDS
Description = Connect to SQL Server using  FreeTDS Driver
Server = NTS-ENTDBD1\TITAN                   ======> This is a named instance
Port = 1433
Database = prod01

Output of tsql -C
Compile-time settings (established with the "configure" script)
                            Version: freetds v0.91
             freetds.conf directory: /etc
     MS db-lib source compatibility: yes
        Sybase binary compatibility: yes
                      Thread safety: yes
                      iconv library: yes
                        TDS version: 4.2
                              iODBC: no
                           unixodbc: yes
              SSPI "trusted" logins: no
                           Kerberos: yes

Output of odbcinst -j
unixODBC 2.2.14
DRIVERS............: /etc/odbcinst.ini
SYSTEM DATA SOURCES: /etc/odbc.ini
FILE DATA SOURCES..: /etc/ODBCDataSources
USER DATA SOURCES..: /etc/odbc.ini
SQLULEN Size.......: 8
SQLLEN Size........: 8
SQLSETPOSIROW Size.: 8

Output of locate libtds
/usr/lib64/libtdsS.so.2
/usr/lib64/libtdsS.so.2.0.0
/usr/lib64/libtdsodbc.so.0
/usr/lib64/libtdsodbc.so.0.0.0

I  have spent countless hours to debug unsuccessfully.  Can anyone lend a hand, please!!!!

Thank You,

Solomon






Confidentiality Notice: The information contained in this e-mail and any attachments (including, but not limited to, any attached e-mails) may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachment for any purpose, nor disclose all or any part of the contents to any other person.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.unixodbc.org/pipermail/unixodbc-support/attachments/20160317/65ee26fc/attachment.html>


More information about the unixODBC-support mailing list