sql server - is it possible execute a perl script with admin rights or as a specific user? -


i'm writing perl script in i've shutdown mssql server ,do operation , i've restart it.i know 1 way use netstat stopt service cann't use that. tried installing dbi , dbd::odbc module. more info here :shutdown mssql server perl script dbi when trying shutdown server using command

$dbh->prepare("shutdown nowait "); 

it's not working me : got response community

shutdown permissions assigned members of sysadmin , serveradmin fixed server roles, , not transferable. i'd consider unlike(hopefully) perl run rights.

so please tell me there way run above command these users ? or can other . note have constraint tha ti cann't stop windows service.

if scripts executed through web browser user executing scripts defined web server. not idea fiddle user. leave things are.

what can create perl script being run privileged user on consistent basis cron.

this script being run cron can check specific content file has been written script user executing script has lesser privileges.

so way work follows:

  1. you execute browser.cgi through browser specific task.

  2. browser.cgi writes instructions file.

  3. every 1 minute priveleged.cgi executes via cron. (the root user execute priveleged.cgi)

  4. priveleged.cgi reads file browser.cgi has written instructions , starts , stops services according instructions.


Comments