Showing posts with label User Profile. Show all posts
Showing posts with label User Profile. Show all posts

Saturday 10 October 2015

User Profile Service Application Notes




The People Picker Control in SharePoint 2013 & 2016
  • The People Picker control is used to find user, groups and claims.  You'll notice the people picker UI has 2 queries (you can normally see the lag), firstly the people picker looks at the UserInfo list in the local site collection and then it also looks at Active Directory (this is where the custom claims providers need to be written if you don't use AD).  A common misconception is thinking the people picker users the UPA to look for users, it does not use the UPA directly.  Indirectly, if the UserInfo is populated the People Picker gets the user from the 1st lookup.
  • The UserInfo table is populated with the initial stub when a user is added to the security or the 1st time the login to the site collection.  
  • The UserInfo list is not updated if you add the user via an AD group or if you pick the user in a list within a people picker column.
  • The UserInfo on each site collection gets an initial stub of information in the list and a timer job at the web application level looks for a list of users to perform a sync (update more into for the user in the userinfo table), this runs every 5 minutes by default.  Job is: User Profile to SharePoint Quick Sync.


Wednesday 16 May 2012

User Profile Service Sync Setup

Overview:  This post assumes UPS is setup and work and merely shows how to amend the synchronisation of AD with the User Profile Service (UPS).










Verify the Synchronisation has run:




Sources/More Info:

http://www.harbar.net/archive/2011/07/12/332.aspx
http://www.harbar.net/archive/2011/02/10/account-deletion-and-sharepoint-2010-user-profile-synchronization.aspx

Thursday 8 March 2012

Setting up User Profiles Reminder

Problem:  Over the last few years I have to re-setup user profiles fairly often and each time I try do it from memory and it fails.  Once again tonight I messed it up on the 1st run.

Resolution:
This Technet article on UPS is key follow the steps: http://technet.microsoft.com/en-us/library/ee721049.aspx
Good simple video on setting up the AD connection and synchronising the UPS http://www.microsoft.com/resources/technet/en-us/office/media/video/video.html?cid=stc&from=mscomSTC&VideoID=04fc6247-66ae-4902-9e5e-7c6fd030ef0f

More Info:

PowerShell to determine NetBios/Hostname and FQDN on the local machine:
PS> $obj_IPProperties = [System.Net.NetworkInformation.IPGlobalProperties]::GetIPGlobalProperties()
PS> "FQDN: {0}.{1}" -f $obj_IPProperties.HostName, $objIPProperties.DomainName
PS> $obj_Computer = Get-WmiObject -Class Win32_ComputerSystem
PS> "NetBios: {0}" -f $obj_Computer.Name

Saturday 4 February 2012

Presence Indicator not working

Problem: Presence indicator is not working in SP2010.

Initial Hypothesis: We have Office Communication 2007 installed.  I believe the presence indicator will also work if you are running Windows messanger on each client machine but our issue affected all our users in our test environment.

Resolution: A colleague, Greg Williams figured out how to fix the issue and I have posted it here to help others.  Neither the email address or the SIP are populated in the 'User Information' page (User Information List).
Here is the PS that fixed our issue, Brian Cartmel provided the PS:
$web = Get-SPWeb http://demo.dev
## get the user information list
$list = $web.Lists | where { $_.Title -eq "User Information List" }
## get the system account item
$item = $list.Items | where { $_["Account"] -eq "i:0e.t|ADFS20|paul.beck@demo.dev" }
$item["Title"] = "Paul Beck"
$item["SIP Address"] = paul.beck@demo.dev
$item.Update()



Explaination: "If the user does have a profile then the hyperlink will redirect to the user's main profile page under My Site. If the user does not have a profile, the hyperlink will redirect to the SharePoint Foundation 'User Information' page. All users in a site have a 'User Information' page, if they also have a User Profile the settings from the profile are synchronised down to the User Information page on a scheduled basis (by a timer job).
The key piece of information to make the presence work is the user's SIP Address which is basically their IM address (This is not always the same as email address). When a users is either added to a site in SharePoint or has their profile imported, the SIP Address will be drawn from Active Directory which is where OCS stores it and placed into the SIP address field in either the user's profile which will in turn synchronise down to the site's local 'User Information' page."  Martin Kearn

Tip: So as long as email or sip is populate with the email, the status indicator works.

More Info:
http://sharepoint.stackexchange.com/questions/15446/presence-indicators-without-lync
http://erikswenson.blogspot.com/2009/12/sharepoint-presence-not-showing.html
http://kbalertz.com/2448575/SharePoint-presence-information-appear-correctly-People-search-results-intermittently.aspx
http://blogs.msdn.com/b/uksharepoint/archive/2010/05/07/office-communicator-integration-presence-in-a-custom-webpart-for-sharepoint-2010.aspx (Read this)
http://blog.falchionconsulting.com/index.php/2011/12/updating-sharepoint-2010-user-information/
http://sharepintblog.com/2011/06/17/update-system-account-user-information-on-a-local-sharepoint-install/  Great blog and source of the Poweshell.

Monday 2 January 2012

Restoring dev machine nightmare

Problem: I have a been battling for days with my User Profile service, somewhere along the line it got corrupted with a CU. 

Hypothesis: I tried permissions, restarting the service, re-provisioning the service, nothing seemed to fix the issue.  Ultimately, I rolled back my VM to a clean install and used Spencer Harbar's guide after installing the August (re-issued) CU 2011.  This fix my User profile service.  Just extremely glad this is a dev machine.  Technet has an good article also on setting up the UPS.
Lastly I'm needed to redeploy all my custom code and restore the site collections to get me data.  The site collections have been transferred using backups can be done thru: 1) CA or 2) PowerShell
Restore the site collection using PowerShell PS> Restore-SPSite -Identity http://test.demo.dev/sites/kbtest -Path "C:\Users\Administrator\Desktop\KB\kbsitecollection.bak" -force
More Info:

PS to backup a Site Collection:
Backup-SPSite -Identity -Path [-Force] [-NoSiteLock] [-UseSqlSnapshot] [-Verbose]
PS> Backup-SPSite -Identity http://demo.dev -Path c:\\backup\SCbackup.bak -force -ea Stop

Note: You can't backup and restore a site collection to the same content database.  If you are using the same web application to restore the site collection, add another content database.

Note: You can only have 1 site collection restored per content database.  I restored a site collection, deleted it as I wanted it with a different name and could not restore.  When I perform the restore using PS I get the gollowing error: "Restore-SPSite : The operation that you are attempting to perform cannot be completed successfully. No content databases in the web application were available to store your site collection. The existing content databases may have reached the maximum number of site collections, or be set to read-only, or be offline, or may already contain a copy of this site collection. Create another content database for the Web application and then try the operation again."

Repair the orphaned items for the offending content database:
PS> $cdb = Get-SPContentDatabase "ContentDB_Portal"
PS> $cdb.Repair($true)
PS> $cdb.Update()


More Info:
Take control of the restored content database
http://technet.microsoft.com/en-us/library/cc288148(v=office.12)