问题
I have a DNN7 installation running on my local machine. This is for development purposes, and I wanted to use IIS instead of Cassini for this. The app is bound to HTTP port 81. All is working well, even though the UsePortNumber
appsetting is not turned on.
All is well. Now I wanted to clone my setup to do some experiments. Here are the steps I took:
- Duplicated the website folder.
- Created a new IIS app pointing to that folder, bound to port 82.
- Duplicated the DotNetNuke7 database.
However, when I try to access my site I get this error:
Domain Name xyz Does Not Exist In The Database
With an entire explanation following that message.
My situation and issue are similar to this other question. I've tried the solution mentioned there, but adding the UsePortNumber
appSetting didn't work. I didn't expect it to work at any rate, since my regular instance is already running on a nonstandard port (81), and it's working fine.
So I figured perhaps port 81 is still mentioned somewhere in a file perhaps, so I used Powershell to do this:
dir *.* -recurse | select-string ":81" | select-object -unique
But nothing relevant came up.
So something is different in my scenario from the other question, but I can't seem to figure out what. Anyone got a clue what's going on here?
回答1:
You've probably forgotton one or two of these steps:
First, don't forget to change the connection string, e.g.:
<add name="SiteSqlServer"
connectionString="Data Source=localhost;Database=DotNetNuke7Clone;User=somebody;Password=something"
providerName="System.Data.SqlClient"/>
Or the appSetting:
<add key="SiteSqlServer"
value="Data Source=localhost;Initial Catalog=DotNetNuke7Experiments;User ID=sa;Password=HagelBaksteen77!"/>
Second, update the portal alias table, e.g.:
UPDATE PortalAlias SET HTTPAlias = REPLACE(HTTPAlias, ':81', ':82')
UPDATE PortalSettings SET SettingValue = REPLACE(SettingValue, ':81', ':82')
来源:https://stackoverflow.com/questions/26143589/duplicated-dnn7-installation-and-now-getting-domain-name-xyz-does-not-exist-in