I need some help trying to deploy an asp.net 2.0 old website.
I am running: Window 10 version 1803, IIS version 10.0.17134.1
Currently the server is running a wordpress site connected to MySQL (let's call it wrong-wp.com). I am trying to deploy an old legacy ASP.NET 2.0 site (let's call it right-aspnet.com), with SQL Server 2014.
First I tried to browse right-aspnet.com, but IE edge gave me this error
Error Code: INET_E_DOWNLOAD_FAILURE
.
Chrome gave me this
error: empty page return
.
I restarted the server, restarted my computer, nothing changed. So I added an html page, index.htm. Both browser rendered fine, both return the page. So I figured it is not a problem with DNS. Maybe I was wrong. When I browse the site, I realized both browsers tried to add www in front of the domain, so I bind the www.right-aspnet.com and added onto the host file.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Host 'wrong-wp.com' is not allowed to connect to this MySQL server
Source Error:
Line 175: <siteMap>
Line 176: <providers>
Line 177: <add name="MySqlSiteMapProvider" type="MySql.Web.SiteMap.MySqlSiteMapProvider, MySql.Web, Version=6.9.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/"/>
Line 178: </providers>
Line 179: </siteMap>
Source File: C:\Windows\Microsoft.NET\Framework\v2.0.50727 \Config\machine.config Line: 177
Version Information:
Microsoft .NET Framework Version:2.0.50727.8922;
ASP.NET Version:2.0.50727.8922
Any idea why it is looking into the wrong host 'wrong-wp.com' and trying to connect to MySQL?
Any help to fix this problem is greatly appreciated!! Thanks!!
Create new user with new password and grant privileges:
CREATE USER 'name'@'localhost' IDENTIFIED BY 'pass';
GRANT ALL PRIVILEGES ON *.* TO 'name'@'localhost' WITH GRANT OPTION;
CREATE USER 'name'@'%' IDENTIFIED BY 'pass';
GRANT ALL PRIVILEGES ON *.* TO 'name'@'%' WITH GRANT OPTION;
FLUSH PRIVILEGES;
I got it working by deleting line 177 right out from the machine.config file.
Line 177: <add name="MySqlSiteMapProvider" type="MySql.Web.SiteMap.MySqlSiteMapProvider, MySql.Web, Version=6.9.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/"/>
Since it is pointing to the .net framework directory
C:\Windows\Microsoft.NET\Framework\v2.0.50727 \Config\machine.config
I can safely assume no MySQL is going to be used for any asp.net v2.0 sites.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.