Recently I had to restore a site collection from production in the acceptance farm of a client. The site collection is a HostNamedSiteCollection. In the acceptance farm the corresponding site collection was not working correctly. So I removed that one through the GUI by going to Central Administration > Application Management > Delete site collection.
By doing so the site collection seems to be deleted. For our setup I had to create a new HNSC and over this HNSC I had to restore the production backup. This resulted in the following error:
Restore-SPSite : No content databases are available for this operation but the site collection is scheduled for deletion in at least one content database. Either wait for the deletion operation to complete or create a content database, and then try the operation again. To create a content database, click "Content databases" on the Application Management page, select the Web application to use, and then click "Add a content database". At line:1 char:1 + Restore-SPSite -Identity "http://xxx.yyy.zz" -Path "c:\install_files\back ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~ + CategoryInfo : InvalidData: (Microsoft.Share...dletRestoreSite: SPCmdletRestoreSite) [Restore-SPSite], InvalidOperationException + FullyQualifiedErrorId : Microsoft.SharePoint.PowerShell.SPCmdletRestoreSite
Looking up all deleted sites with PS command Get-SPDeletedSite showed that the deleted site collection was deleted. But this means that the site is still in de DB and marked for deletion (the site is marked for Gradual deletion). If Get-SPDeletedSite does not show the just deleted site it really is deleted.
After this step I had to “really” remove the site with PS commandline:
Get-SPDeletedSite | Remove-SPDeletedSite
After executing this command the PS command Get-SPDeletedSite does not show the site anymore but one still can not restore over a new site collection created with the same name as the deleted site collection, hence the error.
One has to run the timer job “Gradual Site Delete” (go to Central Administration > Monitoring > Review Job Definitions)
Now theHNSC can be created with this PS command:
New-SPSIte "http://xxx.yyy.zz" -HostHeaderWebApplication "http://servername" -OwnerAlias "domain\account"
And restoring with the following PS command went well now:
Restore-SPSite -Identity "http://xxx.yyy.zz" -Path "c:\install_files\backup\ www.bak" -Force -HostHeaderWebApplication "http://servername" -Confirm:$false
When you install the Search Service Application in the 2013 farm, you presumably install it on the Application server first. If you want to extend the Search Topology later on towards other servers (i.e. the QueryProcessingComponent and IndexPartition to the Front Ends) you have to think at which point in time you will do this. I have experienced that after content is being crawled, this is more difficult than before that moment.
I extend my Search Service Applications with the PowerShell script in the TechNet article found here.
Once I tried to accomplish this after the content had been crawled. This resulted in the following error:
Me and my colleague were able to solve this by adding a second index component to the topology and copy everything to a new topology.
So, when possible, extend a Search Topology before content has been crawled. That way it is much easier.
Let me first state that the situation I write about in this article I have experienced in a SharePoint 2013 test farm. I have done some search queries on the internet but I do not have read about it so far.
The test farm is updated with the SharePoint Public Update March. After this update there were several issues. In this post I will talk about the issue I experienced when I wanted to change Site Collection Administrator settings.
When you select site collection you normally see an overview with URL, Title, Description, Primary administrator, E-mail address and Database name. Like below:
The behavior I saw is that no information is shown about the site collection. Strange. See below:
I thought that maybe after clicking OK I would be able to set the administrators but the screen showed “no selection”.
At this moment I have no solution for this, only a workaround. With Powershell I have set the Primary and Secondary Owner Alias (Administrator). Use this cmdlet to do so:
Set-SPSite -Identity http://<url of site collection> -OwnerAlias <domain\user> -SecondaryOwnerAlias <domain\user>
If you have any solution for this behavior I would appreciate it when you share it with me and the readers of this blog. Thanks!
Something I always wondered but never researched until today is why my host header is greyed out of not available when i add a SSL certificate to my website. This is presumably a bug in IIS7.0 (I only work with IIS7.0, don’t know if other versions also have this problem).
When your certificate has a friendly name of “yourdomain.com” then the described behavior occurs. To change the friendly name you have to do this:
- Load MMC;
- Add Certificates snap-in;
- Select Computer Account;
- Select Local Computer;
- Browse to Personal > Certificates;
- Right click to select Properties on your cert;
- Change the Friendly name field to *.yourdomain.com;
- Reload the IIS manager snap-in.
I read about it in this discussion thread at serverfault.com
Today I have connected a SP2010 database to my SP2013 farm to test the upgrade of a client’s website. Some errors appeared in the log which I tried to solve. The first error I tried to solve because it appeared in the application log every half minute was:
Log Name: Application Source: Microsoft-SharePoint Products-SharePoint Foundation Date: 12/18/2012 5:35:14 PM Event ID: 6398 Task Category: Timer Level: Critical Keywords: User: Domain\spfarm Computer: Server.domain.local Description: The Execute method of job definition Microsoft.Office.Server.Search.Monitoring.HealthStatUpdateJobDefinition (ID 9fd01a1d-6f2d-438e-813b-b7cbebe34e9b) threw an exception. More information is included below. Microsoft SharePoint Foundation Usage service application not found.
I solved this by configuring the Usage and Health Data Collection Service Application (by running the wizard). The error disappeared but now the following errors appeared in the application log every minute:
Log Name: Application Source: Microsoft-SharePoint Products-SharePoint Foundation Date: 12/18/2012 5:36:14 PM Event ID: 5586 Task Category: Database Level: Error Keywords: User: Domain\spfarm Computer: Server.domain.local Description: Unknown SQL Exception 2812 occurred. Additional error information from SQL Server is included below. Could not find stored procedure 'dbo.Search_GetRecentStats'.
Log Name: Application Source: Microsoft-SharePoint Products-SharePoint Foundation Date: 12/18/2012 5:36:14 PM Event ID: 6398 Task Category: Timer Level: Critical Keywords: User: Domain\spfarm Computer: Server.domain.local Description: The Execute method of job definition Microsoft.Office.Server.Search.Monitoring.HealthStatUpdateJobDefinition (ID 9fd01a1d-6f2d-438e-813b-b7cbebe34e9b) threw an exception. More information is included below. Could not find stored procedure 'dbo.Search_GetRecentStats'.
These two error and critical events were solved by following this blogpost by Joel Roos http://spjoel.wordpress.com/2012/08/06/could-not-find-stored-procedure-dbo-search_getrecentstats/