Robocopy перестал работать в Запланированной задаче с ОШИБОЧНЫМ отказом Входа в систему 1326 года

Вы рассмотрели установку VPN к экземпляру AWS вместо того, чтобы настроить Сквид? Затем направьте трафик через экземпляр AWS, который избежал бы сквида и является необнаруживаемым. Просто бросок его там. Это точно, как мой друг настроил VPS в Великобритании для доступа к Би-би-си.

1
задан 22 October 2013 в 23:37
4 ответа

When I was doing something similar, I was unable to get it to work without first mapping the drive.

Action 1 in Task Scheduler:

net use z: \\MY.IP\DatabaseBackupsShare mypass /user:myuser

Action 2 in Task Scheduler:

robocopy "C:\MylocalDirBackup" z:  /mir /z /log:"C:\MyLocalDIR\RobocopyTestLog.txt"

Because you're storing the password--ew--use an unprivileged account rather than an admin and give that account a strong password, the least possible privileges for the task, etc.

1
ответ дан 4 December 2019 в 00:34

I would post this as a comment/reply but I don't have enough rep to do that.

How exactly are you launching the scheduled task?

When I've done scheduled tasks with robocopy, I put the entire robocopy command in a .bat file, and then use that for the scheduled task. In other words, I'm NOT scheduling robocopy.exe and specifying runtime parameters - I'm just scheduling the .bat file. You can avoid a lot of syntax issues that way.

0
ответ дан 4 December 2019 в 00:34

are you specifying the account used in the scheduled task? Or are you using the local user? I am with @Katherine about not storing the credentials in the script. If you specify them in the task, you can tell it to use a privileged account. That way you aren't storing it in an easily access space and you can run with a different account for the script on login...

0
ответ дан 4 December 2019 в 00:34

After confirming that task scheduler was indeed using the account expected but still failing I have arrived at a solution using a pass through authentication approach.

  • I created a new local user account at the destination server - MyNewLocalUser
  • I created a new local user account at the host server MyNewLocalUser
  • Both have the same username and password
  • Changed the scheduled task to run under MyNewLocalUser

Robocopy runs successfully when the task is run under this new user.

0
ответ дан 4 December 2019 в 00:34

Теги

Похожие вопросы