Skip to Content.
Sympa Menu

freetds - [freetds] Check for SQL server port mismatch Re: tsql -S works but tsql -H times out

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Morizono, Hiroki" <HMorizono AT cnmcresearch.org>
  • To: "freetds AT lists.ibiblio.org" <freetds AT lists.ibiblio.org>
  • Subject: [freetds] Check for SQL server port mismatch Re: tsql -S works but tsql -H times out
  • Date: Wed, 9 May 2012 15:48:46 -0400

Thanks Eric--

Someone had turned on dynamic ports on the SQL server and didn't set it back
so instead of having the server listening at 1433 like I thought.

tsql -LH 123.123.123.123 showed the portnumber to be up in the 49000 range.

tsql -H 123.123.123.123\\instancename -p portnumber -U

Things worked when instead of using 1433, I set it to the right number.
my freetds.conf
only had

[shortname]
host = 123.123.123.123
instance = instance
tds version = 8.0

and didn't have a port =
in it.

Am guessing that
tsql -S shortname -U sa
was talking to the SQL Server Browser which sent things to the correct
dynamic port


For what it's worth
TDSVER=7.2 tsql -H 123.123.123.123\\instancename -p portnum -U username
on SQL Server 2008 Express
will connect but first throws up the following error
Error 100 (severity 11):
unrecognized msgno
1>

Changing to
TDSVER=8.0
fixes that.





  • [freetds] Check for SQL server port mismatch Re: tsql -S works but tsql -H times out, Morizono, Hiroki, 05/09/2012

Archive powered by MHonArc 2.6.24.

Top of Page