Run a bat with a domain account on windows servers?

Hi,

I need to run a bat with a domain account other than system account that bigfix uses generally.

Is there a way for it, I searched something on web but it does not work:

For example the fixlet below failed:

Completed // Enter your action script here
Completed override wait
Completed completion=job
Completed hidden=true
Completed runas=currentuser
Failed wait “C:\temp\etbackup.bat”

Best regards

You’re on the right track, using override wait. Was the user you wanted to use to run the batch script logged in at the time? There is a different override wait parameter for specifying a particular user, rather than the logged on user.

It’s important to remember that unless you also specify a particular parameter, the command runs with the effective permissions of that user, not with BigFix’s normal SYSTEM permissions. If that user doesn’t have permission to that folder, or to run the bat, or to run any .bats at all, it will fail.

If you can explain a little more about what you’re trying to do, we can probably help you get there.

I have a similar issue. I’m trying to run a command as domain account. When it runs whoami, the output is NT Authority\system. Shouldn’t this rather be the domain account? SET command also shows the local machine account, not the domain info.

override wait
runas=localuser
asadmin=true
user=mydomain\myaccount
password=required
timeout_seconds=360
disposition=terminate
wait cmd.exe /c set > "c:\output.txt"
1 Like