Page 1 of 1

run a batch on a server from a client

Posted: 02 Sep 2010 09:34
by express
hi
i have a batch file on a server that i want a user to be able to run remotely.
can i write another batch file that calls on the remote batch to run as per permissions on the server?
i do not want to give the user remote access to the server as they are not trusted with access, but i do need them to be able to execute the command.
if i just map the drive to the users competer that the batch file resides and run it will it run as per permissions/compatibility on the server?
don't have time to test at the moment or i would do and not ask such a dumb question.

cheers.

Re: run a batch on a server from a client

Posted: 02 Sep 2010 09:53
by orange_batch
AFAIK, running a batch file from a user's computer will run it under the user's context since Windows still acts like big lord overseer.

Another AFAIK, DOS alone can't make a remote computer run a batch file on itself via a local computer.

Re: run a batch on a server from a client

Posted: 02 Sep 2010 09:57
by express
the batch file runs a process on our lims database on the lims server. i want one user to be able to run this batch file (the process in lims) without actually having to be on the server. i'll test it out tonight from my machine when everyone has gone home, the daily backups have run and i have a free run at the server.

Re: run a batch on a server from a client

Posted: 02 Sep 2010 19:26
by ghostmachine4
you don't have to specifically let them execute the batch file remotely using a batch. Set up an interface such as a Web interface. Let the user click on a button. This button can be programmed to run your batch directly at the back end, or you can store the button click into a database table, then at the back end, poll for this database table, check for the button click value. If its there, execute your batch.

All the while, your user doesn't need a batch file to execute your remote batch.