LawCentral
asked on
Classic ASP connecting to SQL Server 2008 R2 error
Hi Experts,
I am trying to migrate a classic ASP site to a webserver (IIS7). All pages are loading fine except the ones requiring Database connectivity to SQL Server 2008 R2. The connection string in use is:
Provider=[SQLNCLI10];Serve r=10.0.0.5 1\DBServer ;Database= Intranet;U id=usernam e;Pwd=pass word;
The error I get is:
ADODB.Recordset error '800a0e7a'
Provider cannot be found. It may not be properly installed.
Following is the architecture and configuration done thus far for the installation:
ARCHITECTURE:
CONFIGURATION:
IIS:
AWYERS>%wi ndir%\syst em32\inets rv\appcmd set AppPool –a ppPool.name:Site1 - processModel.loadUserProfi le:false
[
SQL Server 2008 R2 (running on Windows Server 2008R2 Standard Edition):
Your help is much appreciated.
Kind regards,
HM
I am trying to migrate a classic ASP site to a webserver (IIS7). All pages are loading fine except the ones requiring Database connectivity to SQL Server 2008 R2. The connection string in use is:
Provider=[SQLNCLI10];Serve
The error I get is:
ADODB.Recordset error '800a0e7a'
Provider cannot be found. It may not be properly installed.
Following is the architecture and configuration done thus far for the installation:
ARCHITECTURE:
Webserver:
IIS 7.0 on Windows Server 2008 Standard Edition
Database Server:
SQL server 2008 R2 installed on a separate server running on Windows Server 2008R2 Standard EditionCONFIGURATION:
IIS:
Installed ASP
Application Pool Configuration:
.Net Framework version: No Managed Code
Managed pipeline mode: Classic
Ran following command under elevated command prompt to run the app pool in its isolated storage:
C:\Users\Administrator.BDL[
ASP Configuration:
Enabled parent paths: True
Send Errors to Browser: True
SQL Server 2008 R2 (running on Windows Server 2008R2 Standard Edition):
Enabled remote connections
Firewall:
Opened up ports 135, 1433 and 1434
Added SQL Server Browser service to the excepted program. The path to executable is: C:\Program Files (x86)\Microsoft SQL Server\90\Shared\sqlbrowse r.exe
Access to DB:
Created a user with DBO access to the Database
Tested connectivity by logging in from SSMS 2008 and then running simple queries.
WDAC checking:
Since WDAC is inbuild component of Windows Server 200, I ran following command under elevated command prompt to check for integrity violations on webserver.
SFC /SCANNOW
SFC /SCANNOW
Your help is much appreciated.
Kind regards,
HM
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
If your connection string is pointing to a remote server, then use this:
Dim conn
Set conn = Server.CreateObject("ADODB .Connectio n")
conn.Open "Driver={SQL Server};" & _
"Server=serverName;" & _
"Address=serverName,1433;" & _
"Network=DBMSSOCN;" & _
"Database=DBName;" & _
"Uid=username;" & _
"Pwd=password"
Dim conn
Set conn = Server.CreateObject("ADODB
conn.Open "Driver={SQL Server};" & _
"Server=serverName;" & _
"Address=serverName,1433;"
"Network=DBMSSOCN;" & _
"Database=DBName;" & _
"Uid=username;" & _
"Pwd=password"
ASKER
Hi Cyberwiki,
Thank you for the info. I have now requested the connection string to be edited.
I did install the SQL Server 2008 R2 native client but it did not fix the errors.
Would you have any other suggestions?
HM
Thank you for the info. I have now requested the connection string to be edited.
I did install the SQL Server 2008 R2 native client but it did not fix the errors.
Would you have any other suggestions?
HM
ASKER
HI sammySeltzer,
Can you kindly edit your prior response and take the password out?
I tried your solution and now I get the error:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]SQL Server does not exist or access denied.
Any pointers?
HM
Can you kindly edit your prior response and take the password out?
I tried your solution and now I get the error:
Microsoft OLE DB Provider for ODBC Drivers error '80004005'
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]SQL Server does not exist or access denied.
Any pointers?
HM
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Good pickup. It must have been a typo from a copy paste.
I did take it out and now I get the error:
Microsoft SQL Server Native Client 10.0 error '80004005'
Named Pipes Provider: Could not open a connection to SQL Server [5].
I googled and found below blog post:
http://blog.sqlauthority.com/2009/05/21/sql-server-fix-error-provider-named-pipes-provider-error-40-could-not-open-a-connection-to-sql-server-microsoft-sql-server-error/
All my settings checked against the post.
-HM
I did take it out and now I get the error:
Microsoft SQL Server Native Client 10.0 error '80004005'
Named Pipes Provider: Could not open a connection to SQL Server [5].
I googled and found below blog post:
http://blog.sqlauthority.com/2009/05/21/sql-server-fix-error-provider-named-pipes-provider-error-40-could-not-open-a-connection-to-sql-server-microsoft-sql-server-error/
All my settings checked against the post.
-HM
Are you on the same network as "10.0.0.51"?
Can you ping it?
Have you enabled remote connections on the SQL Server (default should allow TCP/IP)?
Is the instance name correct and the service running?
Are there any firewalls between you and the SQL Server (try turning them all off to verify, then back on one by one)
Can you ping it?
Have you enabled remote connections on the SQL Server (default should allow TCP/IP)?
Is the instance name correct and the service running?
Are there any firewalls between you and the SQL Server (try turning them all off to verify, then back on one by one)
ASKER
Disabling Firewall on the Database server allows the connections though. I have ports 135, 1433 and 1434 open. Are there any other ports I need to open?
PS: Yes, all servers are on the same network.
PS: Yes, all servers are on the same network.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hi Cyberwiki,
Thank you. As pointed out by you the default instance on the DBServer was using 1433. I allocated a static port as well as created an alias. I then allowed the port through firewall and now everything is in sync and buzing again.
Thank you again.
HM
Thank you. As pointed out by you the default instance on the DBServer was using 1433. I allocated a static port as well as created an alias. I then allowed the port through firewall and now everything is in sync and buzing again.
Thank you again.
HM
You can request attention for a mod to blank out the password.