1. 显示企业搜索服务信息
Get-SPEnterpriseSear1chService
2. 显示企业搜索服务实例
Get-SPEnterpriseSearchServiceInstance
3. 获取指定的企业搜索服务实例
$ssInstance = Get-SPEnterpriseSearchServiceInstance -Identity 91d00542-76cf-417b-aafb-dbfae76a1814
4. 配置企业搜索的爬网账户
Set-SPEnterpriseSearchService –Identity 9e19864d-8b4b-4fda-bcb1-10645457ad70 -CrawlAccount "SP\SharePointCrawl" -CrawlPassword (ConvertTo-SecureString -asplaintext -force -string "SharePoint1")
5. 配置企业搜索服务执行级别
Set-SPEnterpriseSearchService –Identity 9e19864d-8b4b-4fda-bcb1-10645457ad70 –PerformanceLevel Reduced
6. 显示企业搜索服务应用程序
Get-SPEnterpriseSearchServiceApplication
7. 获取指定的搜索服务应用程序
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3
8. 获取自定义元数据分类
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 New-SPEnterpriseSearchMetaDataCategory -Name "Custom Properties" –SearchApplication $ssApp
9. 显示可用的元数据分类
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 Get-SPEnterpriseSearchMetadataCategory –SearchApplication $ssApp
10. 获取指定的元数据分类
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $category = Get-SPEnterpriseSearchMetadataCategory –SearchApplication $ssApp –Identity "Custom Properties"
11. 创建一个自定义爬网元数据属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $category = Get-SPEnterpriseSearchMetadataCategory –SearchApplication $ssApp –Identity "SharePoint" New-SPEnterpriseSearchMetadataCrawledProperty -Name "ows_NewField" –SearchApplication $ssApp –Category $category -VariantType 31 -PropSet 00130329-0-0130-c-131346 -IsNameEnum $false
-VariantType
Text —31
Integer —20
Date and Time —64
Yes/No —11
Binary Data —12
12. 显示可用的爬网属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 Get-SPEnterpriseSearchMetadataCrawledProperty –SearchApplication $ssApp
13. 获取指定的元数据爬网属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $crawledproperty = Get-SPEnterpriseSearchMetadataCrawledProperty –SearchApplication $ssApp –Name "ows_NewField"
14. 创建一个自定义元数据托管属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $category = Get-SPEnterpriseSearchMetadataCategory –SearchApplication $ssApp –Identity "SharePoint" New-SPEnterpriseSearchMetadataManagedProperty -Name "NewField" –SearchApplication $ssApp -Type 1
-Type
Text —1
Integer —2
Decimal —3
DateTime —4
YesNo —5
Binary —6
15. 显示可用的托管属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 Get-SPEnterpriseSearchMetadataManagedProperty –SearchApplication $ssApp
16. 获取指定的元数据托管属性
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $managedproperty = Get-SPEnterpriseSearchMetadataManagedProperty –SearchApplication $ssApp –Identity NewField
17. 创建一个元数据映射
$ssApp = Get-SPEnterpriseSearchServiceApplication -Identity 81aedaf7-704c-47f4-8173-5e99a7495ac3 $crawledproperty = Get-SPEnterpriseSearchMetadataCrawledProperty –SearchApplication $ssApp –Name "ows_NewField" $managedproperty = Get-SPEnterpriseSearchMetadataManagedProperty –SearchApplication $ssApp –Identity NewField New-SPEnterpriseSearchMetadataMapping -SearchApplication $ssApp -ManagedProperty $managedproperty -CrawledProperty $crawledproperty