Metadata Service Permission configuration - termstore access

22/01/2012 19:25

Managed Metadata Service Permissions configuration
Powershell Script :->
Write-Output “Managed Metadata Service Application Permissions”
$spapp = Get-SPServiceApplication -Name “Managed Metadata Service”
$spguid = $spapp.id
$security = Get-SPServiceApplicationSecurity $spguid -Admin      
Grant-SPObjectSecurity $security -Principal “Domain\username” -Rights “Full Control”
Set-SPServiceApplicationSecurity $spapp $security –Admin
(Get-SPServiceApplicationSecurity $spapp -Admin).AccessRules

 

   Write-Output “Term Store Administrators” 

   $taxonomySite = get-SPSite “http://centraladminurl
    #Connect to Term Store in the Managed Metadata Service Application
    $taxonomySession = Get-SPTaxonomySession -site $taxonomySite
    $termStore = $taxonomySession.TermStores[$metadataService]
    $termStore.AddTermStoreAdministrator(“Domain\Username”)

    #Update the Term Store
    $termStore.CommitAll()
    $taxonomySite.Dispose()