[freetds] sql2005 & freetds connection probs

Igor Korot ikorot at earthlink.net
Tue May 13 12:08:32 EDT 2008

Can you telnet to this machine on this port?

Thank you.

-----Original Message-----
>From: S Willms <slwillms at hotmail.com>
>Sent: May 13, 2008 8:55 AM
>To: freetds at lists.ibiblio.org
>Subject: [freetds] sql2005 & freetds connection probs
>Freetds newbie here.
>My goal is to access a MS sql2005 DB from linux through perl using dbd::sybase module.  I've installed freetds v 0.64...is it compatible w/2005?  I wasn't able to find much documentation that refers to sql2005 specifically, but i was able to find one source that says it should work.  Is this right?  Or is there anything else I should be using instead?
>Here's what I've done so far:  I'm able to connect successfully to a MS sql2k DB on another server using "/usr/local/freetds/bin/tsql -H trust -p 1433 -U test".  But using "/usr/local/freetds/bin/tsql -H sql2005 -p 1433 -U test", I get:
>locale is "C"
>locale charset is "ANSI_X3.4-1968"
>Msg 20009, Level 9, State 0, Server OpenClient, Line 0
>Server is unavailable or does not exist.
>There was a problem connecting to the server
>The log file says:
>10:23:19.722219 26609 (util.c:288):Starting log file for FreeTDS 0.64
>        on 2008-05-13 10:23:19 with debug flags 0xffff.
>10:23:19.728044 26609 (iconv.c:195):names for ISO-8859-1: ISO-8859-1
>10:23:19.728110 26609 (iconv.c:195):names for UTF-8: UTF-8
>10:23:19.728138 26609 (iconv.c:195):names for UCS-2LE: UCS-2LE
>10:23:19.728164 26609 (iconv.c:195):names for UCS-2BE: UCS-2BE
>10:23:19.728191 26609 (iconv.c:361):iconv to convert client-side data to the "ANSI_X3.4-1968" character set
>10:23:19.730553 26609 (iconv.c:514):tds_iconv_info_init: converting "US-ASCII"->"UCS-2LE"
>10:23:19.731171 26609 (iconv.c:514):tds_iconv_info_init: converting "ISO-8859-1"->"UCS-2LE"
>10:23:19.731219 26609 (net.c:168):Connecting to port 1433.
>10:23:19.731749 26609 (net.c:256):connect error: Connection refused
>10:23:19.731795 26609 (util.c:119):Changing query state from IDLE to DEAD
>10:23:19.731889 26609 (token.c:2252):tds_client_msg: #20009: "Server is unavailable or does not exist.".  Connection state is now 4.
>10:23:19.731927 26609 (mem.c:519):tds_free_all_results()
>        host = trust
>        port = 1433
>        tds version = 8.0
>        host = sql2005
>        port = 1433
>        tds version = 8.0
>I can successfully ping the sql2005 server using both the DNS name and IP, but neither works to connect to the DB.  However, I was able to successfully connect to sql2005 by creating an ODBC connection on my windows workstation using the same credentials, so I'm assuming (??? correct me if i'm wrong) the server and the DB are correctly setup for remote connections and port 1433 is open.  Windows firewall is turned off on the sql2005 server.
>What am I missing here?
>Windows Live SkyDrive lets you share files with faraway friends.
>FreeTDS mailing list
>FreeTDS at lists.ibiblio.org

More information about the FreeTDS mailing list