[freetds] can't connect through php
Aliet Santiesteban Sifontes
alietss at yahoo.com
Mon Jun 28 22:33:27 EDT 2004
I have exactly that platform and versions, here what I
1-Download latest stable version of freetds.
2-Built the rpm of freetds using it's spec file on
Fedora Core 2, using tds 8.0 as default on configure
and enable microsoft dblib, see ./configure --help for
3-Download Fedora Core 2 php srpm.
4-Install freetds rpms.
5-Rebuild rpm of php using mssql option.
6-Change /etc/freetds.conf settings to use tds 8.0
7-Added mssql server 2000 server settings on
/etc/freetds.conf, I'm using sql security, not
domains, be sure to add this, see the file for
8-Verify conectivity with sql server 2000, a good way
could telnet mssqlserver.com 1433.
9-Add a sql user, with access to your desired
10-write your php script, and connect to the sql
server 2000, use the name you set for the sql server
on the conection.
You should have no problems...
--- "Cory D. Wiles" <cwiles at eperformax.com> wrote:
> OS:Fedora Core 2
> PHP: 4.3.6
> MSSQL 2000 server
> I was able to install freetds just fine and I am
> able to telnet/use tsql
> to connect to the database but when I try to do it
> through my php test
> page I get a failed connection error. I checked my
> freetds log and this
> is what it said:
> TDS: Write failed in tds_write_packet
> Error: 111 (Connection refused)
> 12:01:32.279874 tds_client_msg: #20006: "Write to
> SQL Server failed.".
> Connection state is now 0.
> 12:01:32.279980 tds_process_login_tokens()
> 12:01:32.280024 looking for login token, got 0()
> 12:01:32.280055 tds_process_default_tokens() marker
> is 0()
> 12:01:32.280084 leaving tds_process_default_tokens()
> connection dead
> 12:01:32.280121 tds_client_msg: #20014: "Login
> incorrect.". Connec
> state is now 4.
> 12:01:37.329451 UNIMPLEMENTED dbsettime()
> 12:01:37.329582 UNTESTED dbsetmaxprocs()
> Any suggestion would be greatly appreciated.
> Cory Wiles
> Systems Engineer
> ePerformax - Memphis, TN
> FreeTDS mailing list
> FreeTDS at lists.ibiblio.org
Do you Yahoo!?
New and Improved Yahoo! Mail - Send 10MB messages!
More information about the FreeTDS