Is it possible to restart server from ASP.NET application that is hosted by LocalSystem or LocalService account? This is working when I create custom administrative account and put AppPool to run under that account:
Process.Start("shutdown", "/r /d 4:1 /t 10");
However, I don’t want to have custom accounts (because of password expiry and need to update all AppPools when User passwords are changed – I need to maintain multiple servers).
So, is this possible?
You can always start the process with a different identity that can restart the server:
If you just want to give a non-Administrative account the permission to restart the server:
secpol.msc.Shutdown The System.This might be a good way of using an account for least privilege. That way you don’t have to use a really big hammer like an account in the Administrator group.
Shutdown.exe(I believe) always requires Administrator permissions. You can refer to this MSDN post on restarting the server without shutdown.exe.