Installing SharePoint Portal in Service Manager fails with "An error occurred while executing a custom action"


Symptoms


You get the following error message when trying to install SharePoint Portal in System Center 2012 Service Manager:

Configure portal SharePoint Web site
An error occurred while executing a custom action:_CreateSharePointWebSite
This upgrade attempt has failed before permanent modifications were made

Cause


This can occur if the SQL database being used is the 32-bit edition. SharePoint 2010 Foundation server requires a 64-bit version of SQL Server.

Resolution


To resolve this issue, use the 64-bit version of SQL Server.