首页 > 其他 > 详细

SharePoint 2013技巧分享系列 - Active Directory同步显示用户照片

时间:2014-02-27 02:33:27      阅读:499      评论:0      收藏:0      [点我收藏+]

bubuko.com,布布扣

为了保持通讯信息的一致性,需要设置SharePoint,Exchange, Lync等信息同步更新显示,例如,员工头像信息。 本文介绍如何在SharePoint 2013中同步显示Active Directory活动目录用户头像信息。

首先在用户属性Picture中导入AD活动目录属性,进入“Central Administration” -〉“Manage Service Applications”-〉“User Profile Service Application” -〉“Manage User Properties” -〉“Picture”

bubuko.com,布布扣

 

点击“Edit”,编辑Picture属性,

bubuko.com,布布扣

 

添加thumbnailPhoto属性到Picture中,

bubuko.com,布布扣

添加成功后,该属性会显示如下:

bubuko.com,布布扣

点击“OK”,确认保存。

 

退出用户属性编辑页面,进入User Profile主页面“Central Administration” -〉“Manage Service Applications”-〉“User Profile Service Application”,

bubuko.com,布布扣

点击“Start Profile Synchronization”,同步AD活动目录用户配置信息。该步骤会根据用户的数量决定运行时间长短,需要耐心等待。

bubuko.com,布布扣

同步完成后,需要运行以下PowerShell命令更新用户信息:

Update-SPProfilePhotoStore -CreateThumbnailsForImportedPhotos 1 -MySiteHostLocation http://<YourServerName>/People

bubuko.com,布布扣

运行完成后,刷新用户配置页面,即可看到同步后的用户照片。

bubuko.com,布布扣

 

需要注意的是,如果用户照片仍旧无法在SharePoint中显示,需要查看AD的thumbnailPhoto属性是否为空。这里推荐一个免费工具可以快捷查看AD属性,ADExplorer

bubuko.com,布布扣

运行ADExplorer后,按照以下条件查找

bubuko.com,布布扣

 

点击查找结果,在主显示页面会显示AD属性thumbnailPhoto,如果有数字显示则不为空,否则为空。

bubuko.com,布布扣

 

如果需要添加用户照片到AD活动目录,可以在AD服务器上运行以下PS代码,在运行前,需要确认照片已经存在,

$userName = “kevinfan”
$filePath = “c:\temp\kevinf.jpg”
[byte[]]$img = Get-Content $filePath –encoding byte
Get-ADUser –filter {samaccountname –eq $userName} |
Set-ADUser –replace @{thumbnailphoto=$img}

 

欢迎留言分享你的SharePoint 2013开发和设置技巧。

SharePoint 2013技巧分享系列 - Active Directory同步显示用户照片,布布扣,bubuko.com

SharePoint 2013技巧分享系列 - Active Directory同步显示用户照片

原文:http://blog.csdn.net/jv9/article/details/19947851

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!