Issue while mapping SharePoint user profile store with Ad pictures using Update-SPProfilePhotoStore

We ran into an issue while synchronizing user photos in Active Directory to user profile store in SharePoint. These are the steps which I followed to perform the sync

1. Configure Mysites Host site collection
2. Configure User Profile Service application.
3. Create profile synchronization connection with Active Directory
4. Setup the mapping for picture property in user profile with ‘thumbnail’ from Active Directory.
5. Run full profile synchronization
6. Run Update-SPProfilePhotoStore powershell to create thumbnail photos for users

  Update-SPProfilePhotoStore -CreateThumbnailsForImportedPhotos $true -MySiteHostLocation “http://<my site host>”

Here is where i ran into the following issue:

PowerShell command failed with following error message

Update-SPProfilePhotoStore Error

 

Resolution:

The issue as expected is with permissions. The account running this PowerShell command should have Full control on ‘User Profile Service Application’.

Go to Central Admin -> Select user profile service application -> Select Administrators in top ribbon -> Add the account you are running the powershell command and give full control

Administrators for user profile service application

 

Select the ‘User Profile Service’ application again, select ‘Permissions’. Add the account and give full control.

PermissionsNow try running the command, it may take a while to complete, but the command runs successfully.

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Disable feedback surveys in Power Platform

If you have worked in Microsoft 365 PowerApps or Power Automate, you might be familiar with feedback survey which pops up quite often. Microsoft wants your feedback on how likely are your to recommend Power Automate to a friend or colleague? Well, I ran into a conversation in twitter about this survey. Apparently I learnt […]

Read More

Error handling in Azure PowerShell Runbooks

Error handling in Azure PowerShell Runbooks should be handled carefully if not the runbook with continue to Completed state even if there is an Error in the script. Unlike exception, Runbook execution will continue after  an Error  by default. Windows PowerShell has multiple streams of output. Runbooks in Azure work differently in each of these […]

Read More

SharePoint Designer cannot display the item

You run into ‘SharePoint Designer cannot display the item’ error when you are trying to edit an existing workflow setup in Designer quite often when there is a windows update or update to .NET framework installed in your computer. In some cases it may also not allow you to create new workflows. Resolution: Clearing Designer […]

Read More