Subscribe

SDK supports NDMPcopy?

[ Edited ]

Hi,

 

anyone knows if we can use SDK to perform NDMPcopy operations?

 

Thanks

Re: SDK supports NDMPcopy?

There are no ONTAPI interfaces for performing backup tasks currently in the SDK

Re: SDK supports NDMPcopy?

Thanks,

Any plan to include this function?

Regards.

Re: SDK supports NDMPcopy?

As far as I know.. Nope..

Re: SDK supports NDMPcopy?

Thanks a lot nagendrk.

Re: SDK supports NDMPcopy?

Re: SDK supports NDMPcopy?

Thanks, but we need to use NDMPCopy from Windows machine.

Re: SDK supports NDMPcopy?

Would be great to be able to trigger an ndmpcopy with an API call.

Re: SDK supports NDMPcopy?

Hi,

whe can use Invoke-NaSsh to use ndmpcopy commands.

Firs we get NDMP password for filer, then create string with command and then invoke this command.

[string]$NetappSource = "Filer"

[string]$VolSource = "USUARIOS"

# Path in format NetApp ej: USERS/xxxxxx

[string]$FolderSource = "USERS/xxxxxx"

[string]$NetappDestination = "Filer2"

[string]$VolDestination = "PERFIL"

# Ruta completa en formato NetApp ej: PERFIL/xxxxx

[string]$ForlderDestination = "PERFIL/xxxxx"

Start-Transcript -Path c:\log_ndmp.txt

Import-Module DataOnTap

# Get Password NDMP

$NetappList = (

"Filer","Filer2"

)

 

$password = Get-Content encrypted.txt | ConvertTo-SecureString -key (1..16)

$cred = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList "Administrator",$password

$oNdmpConnection = @()

foreach ($NetAppNdmp in $NetappList){

          $oNdmpPass = New-Object -TypeName PSCustomObject | Select-Object NAS,User,Password

          Connect-nacontroller $NetAppNdmp -Credential $cred | Out-Null

          $GetNdmpPass = Invoke-NaSsh ndmpd password administrator

          $oNdmpPass.NAS = $NetAppNdmp

          $oNdmpPass.User = "Administrator"

          $oNdmpPass.Password = $GetNdmpPass.Substring($GetNdmpPass.length - 17,16)

          $oNdmpConnection += $oNdmpPass

 

}

#$oNdmpConnection | ft -Wrap

# Copy Data

$tNow = get-date -format T

$tNow

Connect-NaController $NetappSource -Credential $cred | Out-Null

$sNdmpPassCopy = $oNdmpConnection | Where-Object {$_.NAS -eq $NetappDestination}

[string]$Command = "ndmpcopy -da administrator:$($sNdmpPassCopy.Password.ToString()) /vol/$($VolSource)/$($FolderSource) $($NetappDestination.Substring(0,11)):/vol/$($VolDestination)/$($ForlderDestination)"

$Command

Invoke-NaSsh $Command

$tNow = get-date -format T

$tNow

Stop-Transcript

Re: SDK supports NDMPcopy?

Francisco,

I've developed an standalone java ndmpcopy util, maybe it can be useful to you, if you want to use it from Windows.

Check it out at: http://cronsult.com/jndmpcopy_man.aspx

Robert