Activating didn't work

Nov 24, 2009 at 6:59 PM
Edited Nov 24, 2009 at 7:02 PM

I was looking to see about using this but the feature didn't give me a warm a fuzzy.

  1. Downloaded the package
  2. Added wsp to solution store manually (stsadm -o addsolution ...)
  3. Deployed to web app via central admin
  4. Went to site collection >
  5. Got error when activating (below)

I'm running as uber-admin in a development VM so the user has full access to the SQL server, etc. The feature activation did create a list called "Config store" but the feature isn't activated in the site collection.

UPDATE: I was able to activate it with stsadm.exe and the activatefeature command (with -force). The error happened below when I tried to activate through the UI.

The EXECUTE permission was denied on the object 'proc_putObject', database 'SharePoint_Config', schema 'dbo'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at Microsoft.SharePoint.Utilities.SqlSession.ExecuteNonQuery(SqlCommand command)
at Microsoft.SharePoint.Administration.SPConfigurationDatabase.StoreObject(SPPersistedObject obj, Boolean storeClassIfNecessary, Boolean ensure)
at Microsoft.SharePoint.Administration.SPConfigurationDatabase.PutObject(SPPersistedObject obj, Boolean ensure)
at Microsoft.SharePoint.Administration.SPPersistedObject.Update()
at Microsoft.SharePoint.Administration.SPWebApplication.ApplyWebConfigModifications()
at Microsoft.SharePoint.Administration.SPWebService.ApplyWebConfigModifications()
at COB.SharePoint.Utilities.ConfigStoreFeatureReceiver.FeatureActivated(SPFeatureReceiverProperties properties)
at Microsoft.SharePoint.SPFeature.DoActivationCallout(Boolean fActivate, Boolean fForce)
at Microsoft.SharePoint.SPFeature.Activate(SPSite siteParent, SPWeb webParent, SPFeaturePropertyCollection props, Boolean fForce)
at Microsoft.SharePoint.SPFeatureCollection.AddInternal(Guid featureId, SPFeaturePropertyCollection properties, Boolean force, Boolean fMarkOnly)
at Microsoft.SharePoint.SPFeatureCollection.Add(Guid featureId)
at Microsoft.SharePoint.WebControls.FeatureActivator.BtnActivateFeature_Click(Object objSender, EventArgs evtargs)
at System.Web.UI.WebControls.Button.OnClick(EventArgs e)
at System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument)
at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Coordinator
Nov 25, 2009 at 12:49 PM

Hey Bil,

Hmm, I haven't seen this before. I'm starting to wonder if it could be because I've always been activating the Feature via the provided stsadm script (found in the InstallPackage directory) - I'll try and repro, but I'm afraid it will be a few days until I get to it.

You'll need to be a farm admin (to write to the config database) and have local administrator permissions (to write to web.config), but it sounds like you have those already.

Thanks,

Chris.

 

Dec 1, 2009 at 8:23 PM

Yeah, the UI feature activation is never something that works great. I just did it from the command line and it was fine. I'm running on a farm with multiple WFE which might be the problem but it's all good now.

Jan 7, 2010 at 6:18 PM

I tried deploying it the exact same way as bsimser and got the same error message. My SharePoint is setup as follows:

Simple Farm - Installed as a farm but everything (SQL Server, SharePoint) is installed on only one server.
SharePoint Accounts - All SharePoint accounts are set use the Administrator account (its a development machine)

 

Jan 7, 2010 at 6:43 PM

Found the problem.  The account that the application pool of the SharePoint site collection the feature is activated on needs to have the appropriate SQL permissions.  In my case I switched the account from Network Service to Administrator (this is on a development machine).  When deploying to production server I'll try to figure out what extra SQL permissions are neccessary (rather than switching the account the application pool is running under). Thanks for the app, I look forward to trying it out.

 

Coordinator
Jan 7, 2010 at 8:58 PM

@dmoss,

Glad to hear you got sorted. Don't forget the other option for your production deployment is activating the feature via STSADM - this will definitely work without any permissions changes as it would be using the context of whoever is logged onto the box. (You'd need to log on with an account which has appropriate permissions though obviously).

Chris.