Restart logoff script

Catboxer

[H]ard|Gawd
Joined
Feb 1, 2003
Messages
1,050
Hello,

I'm trying to figure out how to get my logoff script to restart the PC when a user logs off. So far I have tried attaching simple bat/cmd files to the gp object. This executes shutdown with the switches for reboot, force shutdown, and time set to 0 seconds.

Like so: shutdown -r -f -t 0

I know the script runs because I have tested it with the setting to "Show logoff script." The cmd window executes the script, but it seems the account logs off and terminates shutdown before it has a chance to execute. This leaves the PC sitting at the login window. Is there a way to give the script more time to execute? Or perhaps a better solution all together?

 
Have you tried simply doing it without the time? Give it the normal 30 seconds?
 
Yes, same result. I've even navigated to the sysvol and run it as a user and it shuts the machine down almost instantly. But it will not do it in time at log off.
 
Back
Top