Hi,
Now I think I have the full picture in my head.
Let me clarify a bit. In New-VBRFileToTapeObject we have 2 entry points - for servers added as managed ones (-Server parameter) and servers added as file shares (-NASServer parameter). For those added as managed servers we can also choose the underlying path with -Path parameter. Now, as you know, we can get managed servers with Get-VBRServer cmdlet. However, file shares are
also reflected in the output in this case. But -Path parameter works only for those servers added as managed ones
by their IP or DNS. For those added or reflected by UNC path currently there is no way to specify the underlying path. We know this limitation for NAS shares and have plans to mirror this behavior to Powershell. Especially, when it does actually work in the UI.
So, the workaround here is to add the server hosting your share by its IP or DNS and then construct a FileToTapeObject with the underlying path of your choice:
Code: Select all
$creds = Get-VBRCredentials -Name 'Admin'
$server = Add-VBRWinServer -Name 'Server DNS or IP' -Credentials $creds
$objectSpec = New-VBRFileToTapeObject -Server $server -Path 'C:\Backup'
The example above is for Windows. If it is a Linux server hosting file share, add it with
Add-VBRLinux.
Hope it helps,
Oleg