Hi
We've exported the exportpolicy and the corresponding rules from an existing volume on a cluster.
$export_policy = Get-NcExportPolicy -Controller $source -Name $policy_name
$export_rules = Get-NcExportRule -Controller $source -Policy $export_policy
We've created the exact policy on another cluster where this volume is vaulted to.
New-NcExportPolicy -Controller $destination -Name $policy_name
$export_rules | ForEach-Object {
$_ | New-NcExportRule -Controller $destination -Policy $policy_name -EnableSetUid
}
We tried to apply this policy to a clone of this volume, but we didn't found a cmdlet which allows to apply an export policy to a volume.
Get-NcVol returns the Attribut (VolumeExportAttributes.Policy) but Set-NcVol has no paramter that allows to set any additional volume options like the export policy.
Similar command on the cli looks as follows:
volume modify -vserver "vsname" -volume "clonename" -policy "xy"
Is there a way to set options like the ExportPolicy?
We've noticed that there is a Set-NcNfsExport cmdlet but we don't understand how this should work in a clustered DataOntap environment, because it doesn't utilize export policies.
Cmdlet: Set-NcNfsExport
SYNTAX
Set-NcNfsExport [-Path] <String> [-SecurityFlavors <String[]>] [-Anon <String>] [-ReadOnly <String[]>] [-ReadWrite <String[]>] [-Root <String[]>] [-NoSuid] [-VserverContext <String>] [-Controller <NcController[]>] [<CommonParameters>]
Thanks in advance
Christian