Wednesday, March 28, 2012

Named Pipers Provider, error 40, ok from local, error to remote - help

Hi.
I am new to sql server so please bear with me.
Here is the problem.
I am using VWD express to connect to a sql server 2005 db on my local
machine. The site and the sql server are local and everything is fine.
No problems.
I have a sql server hosting plan to host the db. (my local is SQL
Server 2005 and the hosted is Sql Server 2000).
I use the LOCAL VWD website to access the HOSTED sql server and it
connects with no problem. I changed data in the remote version of the
db as a double-check that I am accessing the remote db and not the
local db.
When I go ahead and upload the web site to my web host, different from
the sql host (long story), I get this error (provider: Named Pipes
Provider, error: 40 - Could not open a connection to SQL Server).
Any ideas why this error is happening. My web host verifies that my
connection string is fine, and that if I can connect with my local
machine then there should be no problem and the problems is on the
hosting end.
Thanks in advance,
RanginaldOk. Problem solved. I was using a web host with multiple hosted
domains and I think I probably had some kind of IIS app directrory
problem. I moved the site to its own hosting and all was fine with no
changes needed.
Thanks anyway. Hope this tidbit helps someone.
Rangy
Ranginald wrote:
> Hi.
> I am new to sql server so please bear with me.
> Here is the problem.
> I am using VWD express to connect to a sql server 2005 db on my local
> machine. The site and the sql server are local and everything is fine.
> No problems.
> I have a sql server hosting plan to host the db. (my local is SQL
> Server 2005 and the hosted is Sql Server 2000).
> I use the LOCAL VWD website to access the HOSTED sql server and it
> connects with no problem. I changed data in the remote version of the
> db as a double-check that I am accessing the remote db and not the
> local db.
> When I go ahead and upload the web site to my web host, different from
> the sql host (long story), I get this error (provider: Named Pipes
> Provider, error: 40 - Could not open a connection to SQL Server).
> Any ideas why this error is happening. My web host verifies that my
> connection string is fine, and that if I can connect with my local
> machine then there should be no problem and the problems is on the
> hosting end.
> Thanks in advance,
> Ranginald|||Do you have to connect with named pipes? If not, change the connection string
to connect with TCP/IP (set Network Library=dbmssocn). Assuming that the SQL
connectivity components are properly installed on the web server and you can
ping the database server from the web server, I'd try a few things.
1. Find out the IP address and the TCP port that the SQL instance listens on.
2. Change the connection string to the IP address followed by a comma and
then the TCP port (e.g. set Server=169.12.35.51,5002). If this does not work,
you may have a problem with accessing the port. (if it's the default instance
using the default port, you don't need to test with the port number specified
explicitly).
3. Change the IP to the server name in the Server property of the connection
string, and try again. If this doesn't work, you may have a problem with
resolving the server to the IP address. Try the fully qualified domain name
instead.
If you can connect with TCP/IP, but not with names pipes, you may have a
problem with the ports used by the named pipes being blocked.
Linchi
"Ranginald" wrote:
> Hi.
> I am new to sql server so please bear with me.
> Here is the problem.
> I am using VWD express to connect to a sql server 2005 db on my local
> machine. The site and the sql server are local and everything is fine.
> No problems.
> I have a sql server hosting plan to host the db. (my local is SQL
> Server 2005 and the hosted is Sql Server 2000).
> I use the LOCAL VWD website to access the HOSTED sql server and it
> connects with no problem. I changed data in the remote version of the
> db as a double-check that I am accessing the remote db and not the
> local db.
> When I go ahead and upload the web site to my web host, different from
> the sql host (long story), I get this error (provider: Named Pipes
> Provider, error: 40 - Could not open a connection to SQL Server).
> Any ideas why this error is happening. My web host verifies that my
> connection string is fine, and that if I can connect with my local
> machine then there should be no problem and the problems is on the
> hosting end.
> Thanks in advance,
> Ranginald
>|||How would I find out the TCP port that the SQL instance listens on?
Thanks
Linchi Shea wrote:
> Do you have to connect with named pipes? If not, change the connection string
> to connect with TCP/IP (set Network Library=dbmssocn). Assuming that the SQL
> connectivity components are properly installed on the web server and you can
> ping the database server from the web server, I'd try a few things.
> 1. Find out the IP address and the TCP port that the SQL instance listens on.
> 2. Change the connection string to the IP address followed by a comma and
> then the TCP port (e.g. set Server=169.12.35.51,5002). If this does not work,
> you may have a problem with accessing the port. (if it's the default instance
> using the default port, you don't need to test with the port number specified
> explicitly).
> 3. Change the IP to the server name in the Server property of the connection
> string, and try again. If this doesn't work, you may have a problem with
> resolving the server to the IP address. Try the fully qualified domain name
> instead.
> If you can connect with TCP/IP, but not with names pipes, you may have a
> problem with the ports used by the named pipes being blocked.
> Linchi
> "Ranginald" wrote:
> > Hi.
> >
> > I am new to sql server so please bear with me.
> > Here is the problem.
> >
> > I am using VWD express to connect to a sql server 2005 db on my local
> > machine. The site and the sql server are local and everything is fine.
> > No problems.
> >
> > I have a sql server hosting plan to host the db. (my local is SQL
> > Server 2005 and the hosted is Sql Server 2000).
> >
> > I use the LOCAL VWD website to access the HOSTED sql server and it
> > connects with no problem. I changed data in the remote version of the
> > db as a double-check that I am accessing the remote db and not the
> > local db.
> >
> > When I go ahead and upload the web site to my web host, different from
> > the sql host (long story), I get this error (provider: Named Pipes
> > Provider, error: 40 - Could not open a connection to SQL Server).
> >
> > Any ideas why this error is happening. My web host verifies that my
> > connection string is fine, and that if I can connect with my local
> > machine then there should be no problem and the problems is on the
> > hosting end.
> >
> > Thanks in advance,
> > Ranginald
> >
> >sql

No comments:

Post a Comment