SymptomsThe site cannot be published with the following error:
Site cannot be published with the following error:
The site cannot be published to the specified location.
FTP error: An unexpected exception has occurred. WrongSiteId
And this error is shown in Parallels Plesk Sitebuilder log on page:
Position in list 1 of 66 (the list is sorted by 'Creation date' in descending order)
Message Publish failed
---SWsoft.SiteBuilder.BO.Facade.PublishException: Publish failed: unknown exception
---System.Exception: Exception of type 'System.Exception' was thrown.
Creation date 09:21:00
User name / User ID / 1c13e1e1-119b-4a9e-9905-0b4e0eedee52
User agent Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:220.127.116.11) Gecko/20091221 Firefox/3.5.7 (.NET CLR 3.5.30729)
Requested URL /Wizard/Publish.aspx
IP address 192.168.10.1
Referrer URL http://sitebuilder.hostname:2006/Wizard/Publish.aspx
CauseWrongSiteID Exception is appeared on site publishing step when SiteID stored in Sitebuilder database differs from SiteID stored in web.config of this site. Such situation can occur when site is copied from another Sitebuilder host (as in this case).
ResolutionHere are the steps on how it has been determined and fixed:
1. Get correct SiteID of site "SITE" from Parallels Plesk Sitebuilder database "sitebuilder" (check registry editor for exact name of Sitebuilder database)
select Id from SiteEntity where Alias='SITE';
2. Go to site directory [SitebuilderInstallDir]\Sites\[SiteID]. For example C:\Parallels\Plesk\SiteBuilder\Sites\c5a265af-1386-499e-b711-effc99d3c090
3. Check SiteID stored in web.config file of this site (appSettings section). It was the following:
<add key="SiteId" value="cbe57889-c221-4480-9450-7603befa751a" />
4. Change SiteID to the correct one:
<add key="SiteId" value="c5a265af-1386-499e-b711-effc99d3c090" />
After that site "SITE" has been published successfully.