|
Home > Archive > IIS Server > August 2004 > IIS 6 and SQL server 2000 connection problem
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
IIS 6 and SQL server 2000 connection problem
|
|
| Cam Schwieder 2004-08-27, 6:19 pm |
| Hey everyone,
I have spent the last few hours trying to get my ISAPI dll to connect
to SQL server 2000 using IIS 6 connection pooling, and I have finally
got it working, but I don't understand why it works. I am hoping
someone here can help me.
Problem:
I have a basic ISAPI dll, that was using the below connection string
to connect to our database.
Provider=SQLOLEDB.1;User ID=XXXXXX;Password=XXXXXX;Data
Source=XXXXXXXXXX;Initial Catalog=XXXXXXX;Network Library=DBMSSOCN
It worked fine under IIS 6 if we had the 'Run WWW service in IIS 5.0
isolation mode' checked. However without this checked, it would fail
in the connect call with the following error
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access denied.
Solution:
Anyway, after reading the following post,
http://www.google.ca/groups?hl=en&l...ccess%2Bdenied.
I fixed the problem by adding the default port number (1433) to the
connection string like so
Provider=SQLOLEDB.1;User ID=XXXXXX;Password=XXXXXX;Data
Source=XXXXXXXXXX,1433;Initial Catalog=XXXXXXX;Network
Library=DBMSSOCN
This has solved my problem, and now everything is fine and dandy,
except for the fact that I have no idea why what I did had any affect
my problem.
If someone can answer this for me, I will truly be impressed!!
Thanks in advance for any feedback!
Cam Schwieder
| |
| Egbert Nierop \(MVP for IIS\) 2004-08-27, 6:19 pm |
| "Cam Schwieder" <cschwieder@canadream.com> wrote in message
news:e5fe0098.0408270636.30095534@posting.google.com...
> Hey everyone,
>
> http://www.google.ca/groups?hl=en&l...ccess%2Bdenied.
>
> I fixed the problem by adding the default port number (1433) to the
> connection string like so
>
> Provider=SQLOLEDB.1;User ID=XXXXXX;Password=XXXXXX;Data
> Source=XXXXXXXXXX,1433;Initial Catalog=XXXXXXX;Network
> Library=DBMSSOCN
>
>
> This has solved my problem, and now everything is fine and dandy,
> except for the fact that I have no idea why what I did had any affect
> my problem.
>
> If someone can answer this for me, I will truly be impressed!!
SQL defaults to a default client setting using
FILE://C:\WINDOWS\system32\cliconfg.exe
If IIS6 does not allow a client to dynamically discover a remote port and
library (named pipes/vs TCP/IP) it might be simple a bug or a security
measure...
--
compatible web farm Session replacement for Asp and Asp.Net
http://www.nieropwebconsult.nl/asp_session_manager.htm
> Thanks in advance for any feedback!
> Cam Schwieder
| |
| Cam Schwieder 2004-08-27, 6:19 pm |
| Thanks for the feedback Egbert!
There is a good chance that what you said was our problem. I was assuming
that that SQL Server client would simply use the default port (1433), and
not scan the server for an open port. But when I check our configuration,
the there was an alias for TCP IP to our DB server using a dynamic port.
Thanks for the explaination, at least now I can sleep a little better at
night, 
Cam
"Egbert Nierop (MVP for IIS)" <egbert_nierop@nospam.invalid> wrote in
message news:ursJlZHjEHA.2992@TK2MSFTNGP12.phx.gbl...
> "Cam Schwieder" <cschwieder@canadream.com> wrote in message
> news:e5fe0098.0408270636.30095534@posting.google.com...
>
> SQL defaults to a default client setting using
> FILE://C:\WINDOWS\system32\cliconfg.exe
>
> If IIS6 does not allow a client to dynamically discover a remote port and
> library (named pipes/vs TCP/IP) it might be simple a bug or a security
> measure...
>
> --
> compatible web farm Session replacement for Asp and Asp.Net
> http://www.nieropwebconsult.nl/asp_session_manager.htm
>
>
>
|
|
|
|
|