Skip to Content.
Sympa Menu

freetds - Re: [freetds] connecting to MSSQL 2005

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "James K. Lowden" <jklowden AT freetds.org>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] connecting to MSSQL 2005
  • Date: Sun, 7 Sep 2008 12:14:49 -0400

Jeremy Kister wrote:
> On 9/6/2008 11:27 PM, Jeremy Kister wrote:
> > I'm having a difficult time connecting to a mssql 2005 server.
>
> tsql reports:
> # tsql -S server -U dbun -P dbpw
> locale is "C"
> locale charset is "646"
> Msg 20009, Level 9, State -1, Server OpenClient, Line -1
> Unable to connect: Adaptive Server is unavailable or does not exist
> There was a problem connecting to the server

Message 20009 indicates connect(2) failed. Either the server couldn't be
found, or it didn't respond to a connection request on the specified port.


I would use TDSDUMP to see the details of the connection attempt. If that
isn't enough, use TDSDUMPCONFIG to see how the servername is being
resolved to an IP address.

Also, you can bypass the whole lookup mechanism with:

$ TDSVER=7.0 tsql -H host -p port -U user -P passwd

HTH.

--jkl





Archive powered by MHonArc 2.6.24.

Top of Page