run .bat script - Fails Needs Required Privilege

Discuss RoboTask here
Post Reply
fnbtunderwood
Posts: 3
Joined: Mon Apr 08, 2013 6:22 pm

run .bat script - Fails Needs Required Privilege

Post by fnbtunderwood »

Hello, using RoboTask in Virtual Win 2008 R2 environment. Running RoboTask as a Service. All tasks are working except two. Both look for files and Execute Batch Scripts. I receive the following error: "A required privilege is not held by the client." I have set the Local Policies for the user to Log on as Service and Log on as a Batch Job.

What am I missing? This worked very well in our previous 2003 environment, but I am not able to get these jobs to run as desired.

Thank you for your help.
Oleg
Site Admin
Posts: 3202
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Re: run .bat script - Fails Needs Required Privilege

Post by Oleg »

What is the "Batch Scripts"? I this a .BAT or .CMD file or something else?
What action do you use to Execute Batch Scripts?
What account do you use at service: Local System account or some user account?

I tested BAT files today in service mode, it works without problems and without additional settings.
receive the following error: "A required privilege is not held by the client."
Where do you get this message - in the log or some program send this message when you try to start it in the batch file?
Oleg Yershov
fnbtunderwood
Posts: 3
Joined: Mon Apr 08, 2013 6:22 pm

Re: run .bat script - Fails Needs Required Privilege

Post by fnbtunderwood »

Hello,

The Batch Script is a .BAT file which calls a .VBS script

The action used is the Windows NT/2000/XP Run Program As User function. (This task was written 5 years ago. While looking for this functions name, i found what appears to be its replacement - General - Run Program / Open Document.

- program - cmd.exe
- parameter - /c "location of .BAT file"
- Run As Domain - DomainName.local
- Run As User - User Name
- Run As Password - Password

Service logs on as a Domain User Account that has the log on as Service local policy assigned.

Error messages appears in the log section below the task list area.

Thank you for your help.
Oleg
Site Admin
Posts: 3202
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Re: run .bat script - Fails Needs Required Privilege

Post by Oleg »

If you use authentication parameters in service mode you should turn OFF "Logon task as user" parameter of the task.
See on the screenshot:
Image

This parameter is ON by default and "Run Program as user" action always returns such error in this case.
We have found some problems in this action and we'll make corrections ASAP
Oleg Yershov
fnbtunderwood
Posts: 3
Joined: Mon Apr 08, 2013 6:22 pm

Re: run .bat script - Fails Needs Required Privilege

Post by fnbtunderwood »

Hello,

Thank you for your help and the explaination of the function.

I will test the functionality of this solution and test the new Run Program / Open Document functions today.

As always, you have been very helpful. For what it's worth, i have used this tool for over 8 years and you just keep making it better and better.

Thank you.
Oleg
Site Admin
Posts: 3202
Joined: Thu Jan 01, 1970 1:00 am
Contact:

Re: run .bat script - Fails Needs Required Privilege

Post by Oleg »

I strongly recommend you to install the patch #2 for RoboTask 5.4
The action "Run as User" have a problem at service mode. This patch fixes it.

Also you can try newest version of RoboTask (5.6): http://www.robotask.com/downloads/
See feature history here: http://www.robotask.com/forum/viewtopic.php?f=1&t=1507
Oleg Yershov
Post Reply