Update-SPProfilePhotoStore

汇报配置文件照片存储与 SharePoint Server 兼容。

语法

Update-SPProfilePhotoStore
      -MySiteHostLocation <SPSitePipeBind>
      [-AssignmentCollection <SPAssignmentCollection>]
      [-CreateThumbnailsForImportedPhotos <Boolean>]
      [-NewBaseUri <Uri>]
      [-NoDelete <Boolean>]
      [-OldBaseUri <Uri>]
      [<CommonParameters>]

说明

从 Office SharePoint Server 升级到 SharePoint Server 后,运行 Update-SPProfilePhotoStore cmdlet 以确保 SharePoint 配置文件照片存储与 SharePoint Server 兼容。 仅在 Update-SPProfilePhotoStore 从 Office SharePoint Server 升级完成后才应使用该 cmdlet。 Update-SPProfilePhotoStore使用 cmdlet 时,会从原始照片创建三个具有可预测大小和名称的缩略图版本,新照片将放置在“我的网站主机的用户照片”库中,并更新配置文件数据库中的属性值。

During the operation, the original image is left as-is. If the operation fails for certain users for any reason, it continues on to the next user.

During the migration of profile photos from one server URL to another, one can use the OldBaseUri and NewBaseUri parameters. You just need to specify the starting portion of the URL that has changed from old to new and an attempt to rebase the profile picture URLs will occur.

例如,OldBaseUri: ; https://server1/my/ProfilePhotosNewBaseUri: https://server1/my/NewLocation/ProfilePhotos

有关适用于 SharePoint 产品的 Windows PowerShell 的权限和最新信息,请参阅 SharePoint Server cmdlet

示例

------------------EXAMPLE-------------------

Update-SPProfilePhotoStore -MySiteHostLocation https://mysites

此示例将照片上载到指定的“我的网站”宿主位置。

参数

-CreateThumbnailsForImportedPhotos

为所有已导入的用户配置文件图片创建缩略图。

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition

-MySiteHostLocation

指定“我的网站”宿主位置的 URL,照片将上载到该位置。

Type:SPSitePipeBind
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition

-NewBaseUri

指定配置文件图片的新 URL。 例如,https://server2/。

Type:Uri
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition

-NoDelete

当值设置为 true 时,为其创建缩略图后,将保留导入的用户配置文件图片文件。

备注

只有在 CreateThumbnailsForImportedPhotos 设置为 $true

Type:Boolean
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition

-OldBaseUri

指定配置文件图片的旧 URL。 例如,https://server1/。

Type:Uri
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition

-工作分配

Manages objects for the purpose of proper disposal. Use of objects, such as SPWeb or SPSite, can use large amounts of memory and use of these objects in Windows PowerShell scripts requires proper memory management. Using the SPAssignment object, you can assign objects to a variable and dispose of the objects after they are needed to free up memory. When SPWeb, SPSite, or SPSiteAdministration objects are used, the objects are automatically disposed of if an assignment collection or the Global parameter is not used.

When the Global parameter is used, all objects are contained in the global store. If objects are not immediately used, or disposed of by using the Stop-SPAssignment command, an out-of-memory scenario can occur.

Type:SPAssignmentCollection
Position:Named
Default value:None
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server Subscription Edition