|
|
Data ONTAP® PowerShell Toolkit
|
Cmdlet: Set-NcVol
NAME
Set-NcVol
SYNOPSIS
Set the specified volume online, offline, or restricted.
SYNTAX
Set-NcVol [-Name] <String> [-Online] [-Offline] [-Restricted] [-VserverConte
xt <String>] [-Controller <NcController[]>] [<CommonParameters>]
Set-NcVol [-Name] <String> [-Online] [-Offline] [-Restricted] -InfiniteVolum
e [-VserverContext <String>] [-Controller <NcController[]>] [<CommonParamete
rs>]
DESCRIPTION
Set the specified volume online, offline, or restricted.
Online: Bring the specified volume online. This command takes effect immedia
tely. If there are CIFS shares associated with the volume, they are enabled
.
Offline: Take the specified volume offline, making it unavailable for user-l
evel data access. The operation takes effect before the API returns except i
n maintenance mode, when the current root volume may not be taken offline.
A volume marked to become the root cannot be taken offline. Taking a flexib
le volume offline does not affect its containing aggregate in any way. A num
ber of operations being performed on the given volume (or its containing agg
regate) can prevent this operation from succeeding, either at all or for var
ious lengths of time. If such operations are found, the system waits up to
one second for them to finish. If they don't, the command is aborted. A che
ck is also made for files on the volume opened by internal ONTAP processes.
The command is aborted if any are found.
Restricted: Restrict the specified volume, making it unavailable for user-le
vel data access.
When run with the InfiniteVolume switch, the cmdlet runs asynchronously. A
job is returned. The status of the job can be tracked using the Job cmdlets
.
PARAMETERS
-Name <String>
Name of an existing volume.
Online: If a volume is specified, it must be currently offline, or restr
icted. If the volume is inconsistent, but has not lost data, it is advi
sable to run WAFL_check or wafliron (or do a 'snapmirror initialize' in
case of a replica volume) prior to bringing an inconsistent volume onlin
e. Bringing an inconsistent volume online increases the risk of further
file system corruption. If the volume is inconsistent and has experien
ced possible loss of data, it cannot be brought online unless WAFL_check
or wafliron (or 'snapmirror initialize') has been run on the volume.
Offline: If a volume contains CIFS shares, users should be warned before
taking the volume offline.
Required? true
Position? 1
Default value
Accept pipeline input? true (ByPropertyName)
Accept wildcard characters? false
-Online
Set the volume online.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Offline
Set the volume offline.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Restricted
Set the volume restricted.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-VserverContext <String>
Vserver to which to direct this command. If the currently connected con
troller (as embodied by an NcController object) represents a cluster, th
ere are multiple means to address commands to one of its vservers. Eith
er set the Vserver field on the NcController object to direct all subseq
uent commands to that vserver, or supply the VserverContext parameter to
an individual cmdlet. Only cmdlets which may be invoked on vservers of
fer the VserverContext parameter.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Controller <NcController[]>
A clustered Data ONTAP controller to receive this cmdlet, as embodied by
an NcController object. This parameter is returned by the Connect-NcCo
ntroller cmdlet. If not specified, the value in the global variable Cur
rentNcController is used. In the latter case, if CurrentNcController co
ntains a collection of NcController objects, this cmdlet is invoked on e
ach controller in succession.
Required? false
Position? named
Default value
Accept pipeline input? true (ByValue, ByPropertyName)
Accept wildcard characters? false
-InfiniteVolume
Specify the InfiniteVolume parameter to indicate the volume is an Infini
te Volume. If a VolumeAttributes object is piped to this cmdlet, the In
finiteVolume switch will be automatically set.
Required? true
Position? named
Default value
Accept pipeline input? true (ByPropertyName)
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer and OutVariable. For more information, type,
"get-help about_commonparameters".
INPUTS
OUTPUTS
DataONTAP.C.Types.Volume.VolumeAttributes
NOTES
Category: volume
API: volume-online, volume-offline, volume-restrict, volume-online-async
, volume-offline-async, volume-restrict-async
Family: vserver
-------------- Example 1 --------------
C:\PS>Set-NcVol vol2 -Online
Set volume 'vol2' online.
Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
vol2 online 10.0 GB 5% 9.5 GB False aggr1 vserver1
-------------- Example 2 --------------
C:\PS>Set-NcVol vol2 -Restricted
Set volume 'vol2' restricted.
Set volume Restricted
Are you sure you want to set volume vol2 to Restricted?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (defau
lt is "Y"): Y
Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
vol2 restricted 10.0 GB aggr1 vserver1
-------------- Example 3 --------------
C:\PS>Set-NcVol vol2 -Offline
Set volume 'vol2' offline.
Set volume Offline
Are you sure you want to set volume vol2 to Offline?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (defau
lt is "Y"): Y
Name State TotalSize Used Available Dedupe Aggregate Vserver
---- ----- --------- ---- --------- ------ --------- -------
vol2 offline 10.0 GB aggr1 vserver1
RELATED LINKS
Get-NcVol
| Copyright © 2013 NetApp. All rights reserved. Use is subject to license terms. |
|
Data ONTAP® PowerShell Toolkit
|