Kashif Nizam Qureshi

Leave a comment

Deleting Project Server Orphaned Sites

Run the following one by one.


$sa = get-spserviceapplication | ? {$_.Id -eq “33c1ead8-9721-4a24-a0aa-4a9b69915952″} // Above guid

followed by

$sc = $sa.SiteCollection

$a = $psi.Sitecollection | where {$_.SiteID -eq “9c601a96-0a44-4bb7-9911-d504b79e7209″} // Above SC SiteID guid

$sc = $sa.SiteCollection // in case you have more SC

$a = $psi.Sitecollection | where {$_.SiteID -eq “cdeeb69f-6858-46a6-bd2a-99fe2d2b3f7c”} // Above SC SiteID guid



Note the above once didn’t work for removing one of the instance, it did work well for other once ( I had two). Use the following to delete.
$svApp = Get-SPServiceApplication -Name “Project Web App Service Application”

// First use SITEID, if that doesn’t do anything try with ID from what you get from the above command



Remove-SPServiceApplication $svApp -RemoveData

Leave a comment

Migrating Project Server 2013 to Another Server Using PowerShell

  • Delete existing PWA instance

Dismount-SPProjectWebInstance -SiteCollection  “http://hqoepmapp01:85/PWA”
Dismount-SPContentDatabase AM_Content

  • Delete any old dbs and restore new DBs, backed up from source server
  • Run the following commands one by one, to mount content db and PWA db. And create PWA instance in the last.

Mount-SPContentDatabase AM_Content -DatabaseServer HQOEPMDB01\StagingEPM –WebApplication http://hqoepmapp01:85/

Mount-SPProjectDatabase -Name AM_ProjectWebApp –WebApplication http://hqoepmapp01:85/ –DatabaseServer HQOEPMDB01\StagingEPM

Mount-SPProjectWebInstance –DatabaseName AM_ProjectWebApp –SiteCollection http://hqoepmapp01:85/PWA –DatabaseServer HQOEPMDB01\StagingEPM

  • I had to run the following command as well in order to make the site accessible.

Sync-SPProjectPermissions -Url http://hqoepmapp01:85/PWA -Type “Full”
Set-SPPRojectPermissionMode -Url http://hqoepmapp01:85/PWA -AdministratorAccount am\epmfarm -Mode ProjectServer

Leave a comment

SharePoint 2013 Designer Workflow Error Access Denied


RequestorId: 675358e8-c91d-0f3a-ebaa-d663a9a1202d. Details: System.ApplicationException: HTTP 401 {“error”:{“code”:”-2147024891, System.UnauthorizedAccessException”,”message”:{“lang”:”en-US”,”value”:”Access denied. You do not have permission to perform this action or access this resource.”}}} {“Transfer-Encoding”:[“chunked”],”X-SharePointHealthScore”:[“0″],”SPRequestGuid”:[“6359f5a3-808a-4144-ace2-0fdff207809f”],”request-id”:[“6359f5a3-808a-4144-ace2-0fdff207809f”],”X-FRAME-OPTIONS”:[“SAMEORIGIN”],”MicrosoftSharePointTeamServices”:[“″],”X-Content-Type-Options”:[“nosniff”],”X-MS-InvokeApp”:[“1; RequireReadOnly”],”Cache-Control”:[“max-age=0, private”],”Date”:[“Sun, 30 Nov 2014 08:08:36 GMT”],”Server”:[“Microsoft-IIS\/8.0″],”WWW-Authenticate”:[“NTLM”],”X-AspNet-Version”:[“4.0.30319″],”X-Powered-By”:[“ASP.NET”]} at Microsoft.Activities.Hosting.Runtime.Subroutine.SubroutineChild.Execute(CodeActivityContext context) at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager) at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)

Resolution 1:

PS C:\Users\exceed.epm> Get-SPTimerJob “RefreshMetadataFeed” | Start-SPTimerJob

Resolution 2 (In my case it worked):

Activate site feature “Workflows can use app permissions

Site actions > Site Settings > Site features > Workflows can use app permission

Leave a comment

Site Collection Feature Activation Failed

I tried activating feature from site collection feature GUI, but threw an error. Just like a normal SP guy, I took shovel and starting digging into SP error logs. At first it was pointing to very unrelated items as given below.

Failed on try1 to load XML document at path ‘C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\Template\Features\NintexLiveAdminLinks\feature.xml': System.IO.DirectoryNotFoundException: Could not find a part of the path ‘C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\15\Template\Features\NintexLiveAdminLinks\feature.xml’.

I kept on digging harding :P deep in its core and found another stupid error saying

Getting Error Message for Exception System.Security.SecurityException: Access denied.

After googling for the solution, came to know to use powershell. I used the following comand

Enable-SPFeature “DHA EPM 2013 GRP Job” -url “http://server:123″

The Feature is not a Farm Level Feature and is not found in a Site level defined by the Url.

Without banging my head here and there, I went to feature hive “c:/prog/common/micro/web/15/feature…” and found that feature name is different as “DHA EPM 2013_Feature1″. This could be because I named it sometime back and somehow it kept this in itself. I correct the name in the command and it worked.


Get every new post delivered to your Inbox.