Microsoft Virtualization Discussions

Powershell xx-NANDMPCOPY as scheduled task

JODY_IFVERSEN

I have a need to relocate user home folders based a change in role.   I would like to do this using the powershell xx-NANDMPCOPY commandlets since it would be more efficient than redirecting the data through a host with something like Robocopy.  I have a script which will do this, and have successfully run it interactively.  However, when I try and run it as a scheduled task, the job fails with an 'Incorrect Function' error.

Has anyone successfully gotten the NANDMPCOPY commandlets to run as a scheduled task?  Is this even possible with the current version?

Thanks.

1 REPLY 1

vinith

Hello Jody, Can you paste your code ?

Can you try the below code ?

$trigger = New-JobTrigger -Daily -At 3am

Register-ScheduledJob -Name Start-Copying -Trigger $trigger -ScriptBlock {

<#

#>

ipmo dataontap -ErrorAction SilentlyContinue

Invoke-NaNdmpCopy 10.61.167.61 /vol/vol4/t5/ 10.61.169.28 /vol/vol1/t5/ -SrcAuthType md5 -DstAuthType md5

}

Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public