Compare-VBRLinuxGuestItemsAttributes
Short Description
Compares attributes of Linux-based or Unix-based files and folders from a backup with attributes of original files and folders.
Product Edition: Enterprise, Enterprise Plus, Veeam Universal License
Syntax
|
Compare-VBRLinuxGuestItemsAttributes -LinuxFlrObject <VBRLinuxFlrObject> -Item <VBRFLRFsItem> [<CommonParameters>] |
Detailed Description
This cmdlet compares attributes of Linux-based or Unix-based files and folders from a backup with attributes of original files and folders.
When Veeam Backup & Replication compares files, it compares their attributes. When Veeam Backup & Replication compares folders, it compares folder attributes and file attributes inside the folder recursively. Once a file with changed attributes is found, Veeam Backup & Replication stops comparing files and marks the folder as changed. If you further browse the folder in the compared state, Veeam Backup & Replication continues comparing non-compared files and folders. Veeam Backup & Replication compares the following attributes: Date Modified, Owner, Group, Permissions, Size (only for files).
You cannot compare attributes of a volume (a root item).
Note |
|
Before comparing attributes, you must establish connection with the original machine using the |
Parameters
|
Parameter |
Description |
Type |
Required |
Position |
Accept Pipeline Input |
|---|---|---|---|---|---|
|
Item |
Specifies the file or folder whose attributes you want to compare.
Accepts the |
|
True |
Named |
True (ByPropertyName, ByValue) |
|
LinuxFlrObject |
Specifies a restore session of Linux-based or Unix-based guest OS files. The cmdlet will use this session to compare attributes. Note: The restore session must be started within the current PowerShell session.
Accepts the |
|
True |
Named |
False |
<CommonParameters>
This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see Microsoft Docs.
Output Object
The cmdlet returns the VBRLinuxGuestItemAttributesView object that contains attributes of the compared file or folder from the backup and from the original machine.
Examples
Comparing Attributes of Files and Folders from Backup with Attributes of Original Files and Folders
This example shows how to compare attributes of a file from the UbuntuSrv backup with attributes of the original file.
|
$backup = Get-VBRBackup -Name "UbuntuSrv" $restorepoint = Get-VBRRestorePoint -Backup $backup $server = Get-VBRServer -Name "LinSrv05" $session = Start-VBRLinuxFileRestore -RestorePoint $restorepoint -MountServer $server Connect-VBRLinuxGuestProductionMachine -LinuxFlrObject $session $file = Get-VBRLinuxGuestItem -LinuxFlrObject $session -Path "/home/administrator/mydir/report.txt" Compare-VBRLinuxGuestItemsAttributes -LinuxFlrObject $session -Item $file |
Perform the following steps:
- Run the
Get-VBRBackupReturns backups. cmdlet. Specify theNameparameter value. Save the result to the$backupvariable. - Run the
Get-VBRRestorePointReturns restore points. cmdlet. Set the$backupvariable as theBackupparameter value. Save the result to the$restorepointvariable. - Run the
Get-VBRServerReturns hosts connected to the backup infrastructure. cmdlet. Specify theNameparameter value. Save the result to the$servervariable. - Run the
Start-VBRLinuxFileRestoreStarts a restore session of Linux-based or Unix-based guest OS files. cmdlet. Set the$restorepointvariable as theRestorePointparameter value. Set the$servervariable as theMountServerparameter value. Save the result to the$sessionvariable. - Run the
Connect-VBRLinuxGuestProductionMachineConnects to the Linux-based or Unix-based machine where original files and folders reside. cmdlet. Set the$sessionvariable as theLinuxFlrObjectparameter value. - Run the
Get-VBRLinuxGuestItemReturns Linux-based or Unix-based guest OS files. cmdlet. Set the$sessionvariable as theLinuxFlrObjectparameter value. Specify thePathparameter value. Save the result to the$filevariable. - Run the
Compare-VBRLinuxGuestItemsAttributescmdlet. Set the$sessionvariable as theLinuxFlrObjectparameter value. Set the$filevariable as theItemparameter value.
Related Commands
Connect-VBRLinuxGuestProductionMachineConnects to the Linux-based or Unix-based machine where original files and folders reside.Get-VBRBackupReturns backups.Get-VBRLinuxGuestItemReturns Linux-based or Unix-based guest OS files.Get-VBRRestorePointReturns restore points.Get-VBRServerReturns hosts connected to the backup infrastructure.Start-VBRLinuxFileRestoreStarts a restore session of Linux-based or Unix-based guest OS files.