与 SQL Server 建立连接时发生网络相关或特定于实例的错误
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
当我在网络服务器上上传我的网站并使用连接字符串与远程 sqlserver2005 连接时......
<connectionStrings>
<remove name="ConnectionString"/>
<add name="ConnectionString" connectionString="Data Source=69.16.253.19,1433;Initial Catalog=vb_usa;Persist Security Info=True;User ID=username;Password=password" providerName="System.Data.SqlClient"/>
</connectionStrings>
它会产生以下错误 - 您可以在我的网页中看到错误:
它在上面显示错误..
http://vbi.volvobusesindia.com 在我的网站 APP_Data 文件夹中使用 aspnetdb.mdf...我在网站中使用的功能是登录控制、密码恢复、注册控制...
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)
when i upload my site on webserver and connect with remote sqlserver2005 using connection string....
<connectionStrings>
<remove name="ConnectionString"/>
<add name="ConnectionString" connectionString="Data Source=69.16.253.19,1433;Initial Catalog=vb_usa;Persist Security Info=True;User ID=username;Password=password" providerName="System.Data.SqlClient"/>
</connectionStrings>
it produces the following errr --
you can see error in my webpage :
http://vbi.volvobusesindia.com
it shows an error above ..
i m using aspnetdb.mdf in my website in APP_Data Folder... features i use in my website is Login Control, Password recovery, signup control...
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
尝试了以上所有方法,但对我不起作用。当我检查服务时,我发现设置为自动的SQLExpress服务没有启动。一旦我启动 SQLExpress 服务,一切就正常了。
Tried all the above but did not work for me. When I checked Services, I found that the SQLExpress service which was set Automatic, was not started. Once I started the SQLExpress service, everything worked.
请参阅此站点中的指南 http://www.connectionstrings.com/sql-server-2005
特别请查看该页面上标题为“在连接到本地 SQL Server Express 实例时附加位于数据目录中的数据库文件”的部分。
格式为:
基本上,您需要连接到安装在 Web 服务器上的 SQL Express 实例并将其指向数据库文件所在的位置。
See the guide in this site http://www.connectionstrings.com/sql-server-2005
In particular look at the section on that page titled "Attach a database file, located in the data directory, on connect to a local SQL Server Express instance"
The format is:
Basically, you need to connect to the SQL Express instance installed on the web server and point it to where your database file is located.
在该远程计算机 (63.15.223.19) 上,SQL 服务未运行。您可以转到该计算机并尝试从命令提示符运行“net start mssqlserver”。
On that remote machine (63.15.223.19), the SQL services are not running. You can go to that machine and try to run "net start mssqlserver" from command prompt.