|
|
Data ONTAP® PowerShell Toolkit
|
Cmdlet: Rename-NaFile
NAME
Rename-NaFile
SYNOPSIS
Rename a file.
SYNTAX
Rename-NaFile [-Path] <String> [-NewPath] <String> [-Controller <NaControlle
r>] [-WhatIf] [-Confirm] [<CommonParameters>]
DESCRIPTION
Rename a file. The source and destination files must be fully qualified and
must reside on the same volume.
PARAMETERS
-Path <String>
Path of the file to rename, i.e. /vol/<volumename>/<filename>.
Required? true
Position? 1
Default value
Accept pipeline input? true (ByPropertyName)
Accept wildcard characters? false
-NewPath <String>
New path of the file, i.e. /vol/<volumename>/<filename>.
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Controller <NaController>
The Data ONTAP controller object, embodied by an NaController object. T
his parameter is returned by the Connect-NaController cmdlet. If not sp
ecified, the value in the global variable CurrentNaController is used.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-WhatIf
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Confirm
Required? false
Position? named
Default value
Accept pipeline input? false
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
NetApp.Ontapi.Filer.File.FileInfo
NOTES
Category: file
API: system-cli
-------------- Example 1 --------------
C:\PS>Rename-NaFile /vol/testvol3/file1.txt /vol/testvol3/file2.txt
Rename file1.txt to file2.txt.
Name Type Size Created
Modified Owner Group Perm Empty
---- ---- ---- -------
-------- ----- ----- ---- -----
/vol/testvol3/file2.txt file 10 B 12/15/2010
12/15/2010 0 0 1077
RELATED LINKS
Get-NaFile
Read-NaDirectory
| Copyright © 2012 NetApp. All rights reserved. Use is subject to license terms. |
|
Data ONTAP® PowerShell Toolkit
|