Using AT to schedule shutdown.exe to reboot win2003 machine
Windows Server Forum Index Windows Server
Server discussion on Windows platform.
 
 FAQFAQ   MemberlistMemberlist     RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 
Google
 
Web winserverhelp.com
Using AT to schedule shutdown.exe to reboot win2003 machine

 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming
Author Message
chinn
Guest





Posted: Tue Dec 21, 2004 8:49 pm    Post subject: Using AT to schedule shutdown.exe to reboot win2003 machine Reply with quote

Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..
Back to top
Jerold Schulman
Guest





Posted: Tue Dec 21, 2004 8:54 pm    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

On Tue, 21 Dec 2004 06:49:05 -0800, "chinn" <chinn@discussions.microsoft.com> wrote:

Quote:
Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..


Try
at \\machine 16:02 /Interactive "C:\restart.bat"

Jerold Schulman
Windows Server MVP
JSI, Inc.
http://www.jsiinc.com
Back to top
chinn
Guest





Posted: Wed Dec 22, 2004 3:07 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

That didn't work.

"Jerold Schulman" wrote:

Quote:
On Tue, 21 Dec 2004 06:49:05 -0800, "chinn" <chinn@discussions.microsoft.com> wrote:

Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..


Try
at \\machine 16:02 /Interactive "C:\restart.bat"

Jerold Schulman
Windows Server MVP
JSI, Inc.
http://www.jsiinc.com
Back to top
Corné Bogaarts
Guest





Posted: Wed Dec 22, 2004 5:40 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

There is a problem with Winlogon in Win2003 (MS KB 834100), that you
bump into if you try to use 'shutdown.exe' to reboot these servers.
The issue arises when a user connects to the server with Terminal
Server Client (mstsc.exe) while using the '/console'-option.

As far as I can tell we only had the problem if you would schedule the
shutdown, not if you use the shutdown command remotely from another
computer.

Before a colleague pointed me out this article I had been testing with
scheduling with 'schtasks', so i could use another user-account than
(local) System for the shutdown command. This didn't help.
Also giving commandline parameters for the 'Shutdown Event Tracker'
didn't help. As you noticed yourself, the /f-ption to 'force' a
shutdown didn't help either.

In the end I managed to work around the problem by using
'tsshutdn.exe' to reboot the computer. It's a shutdown-tool that's
available natively on Win2000 and Win2003 (and WinXP).
It seems actually to be directed at Terminal Servers (hence the 'ts'
in the name), but by default all Win2000 and up run TS to manage the
computer remotely or for remote assistance.


Corné

On Tue, 21 Dec 2004 06:49:05 -0800, "chinn"
<chinn@discussions.microsoft.com> wrote:

Quote:
Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.
Back to top
chinn
Guest





Posted: Wed Dec 22, 2004 6:23 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

But can these be used to shutdown any win2k and Win2003
servers or it has to a Terminal Server Services.

Thanks,
"Corné Bogaarts" wrote:

Quote:
There is a problem with Winlogon in Win2003 (MS KB 834100), that you
bump into if you try to use 'shutdown.exe' to reboot these servers.
The issue arises when a user connects to the server with Terminal
Server Client (mstsc.exe) while using the '/console'-option.

As far as I can tell we only had the problem if you would schedule the
shutdown, not if you use the shutdown command remotely from another
computer.

Before a colleague pointed me out this article I had been testing with
scheduling with 'schtasks', so i could use another user-account than
(local) System for the shutdown command. This didn't help.
Also giving commandline parameters for the 'Shutdown Event Tracker'
didn't help. As you noticed yourself, the /f-ption to 'force' a
shutdown didn't help either.

In the end I managed to work around the problem by using
'tsshutdn.exe' to reboot the computer. It's a shutdown-tool that's
available natively on Win2000 and Win2003 (and WinXP).
It seems actually to be directed at Terminal Servers (hence the 'ts'
in the name), but by default all Win2000 and up run TS to manage the
computer remotely or for remote assistance.


Corné

On Tue, 21 Dec 2004 06:49:05 -0800, "chinn"
chinn@discussions.microsoft.com> wrote:

Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.
Back to top
Corné Bogaarts
Guest





Posted: Wed Dec 22, 2004 11:23 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

I probably should have stated it more clearly: it works on all
computers runing Win2000 server and newer: Wind2000 Server, WinXP and
Win2003.
I'm not sure about WinNT4. WinNT4 Terminal Server Edition should work.

Corné

On Tue, 21 Dec 2004 16:23:04 -0800, "chinn"
<chinn@discussions.microsoft.com> wrote:

Quote:
But can these be used to shutdown any win2k and Win2003
servers or it has to a Terminal Server Services.

Thanks,
"Corné Bogaarts" wrote:

There is a problem with Winlogon in Win2003 (MS KB 834100), that you
bump into if you try to use 'shutdown.exe' to reboot these servers.
The issue arises when a user connects to the server with Terminal
Server Client (mstsc.exe) while using the '/console'-option.

As far as I can tell we only had the problem if you would schedule the
shutdown, not if you use the shutdown command remotely from another
computer.

Before a colleague pointed me out this article I had been testing with
scheduling with 'schtasks', so i could use another user-account than
(local) System for the shutdown command. This didn't help.
Also giving commandline parameters for the 'Shutdown Event Tracker'
didn't help. As you noticed yourself, the /f-ption to 'force' a
shutdown didn't help either.

In the end I managed to work around the problem by using
'tsshutdn.exe' to reboot the computer. It's a shutdown-tool that's
available natively on Win2000 and Win2003 (and WinXP).
It seems actually to be directed at Terminal Servers (hence the 'ts'
in the name), but by default all Win2000 and up run TS to manage the
computer remotely or for remote assistance.


Corné

On Tue, 21 Dec 2004 06:49:05 -0800, "chinn"
chinn@discussions.microsoft.com> wrote:

Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.


--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.
Back to top
aaron
Guest





Posted: Wed Dec 22, 2004 10:49 pm    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

might want to check out the new prefered commmand to schedule tasks.

http://www.microsoft.com/resources/documentation/WindowsServ/2003/standard/proddocs/en-us/Default.asp?url=/resources/documentation/WindowsServ/2003/standard/proddocs/en-us/schtasks.asp



--
aaron
A+,NET+,MCSE 2K/2K3,CNA,CCNA
"chinn" <chinn@discussions.microsoft.com> wrote in message
news:E900527B-567D-4978-ABC1-520DB789ED23@microsoft.com...
Quote:
Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000 servers
and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..
Back to top
aaron
Guest





Posted: Wed Dec 22, 2004 10:51 pm    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

Here is what I use, works fine on all my servers.

shutdown.exe /L /R /Y /C

--
aaron
A+,NET+,MCSE 2K/2K3,CNA,CCNA
"Corné Bogaarts" <does.not.exist@bigfoot.com> wrote in message
news:gs0is0lho6j04t8988nlioumujjh3a1ig9@4ax.com...
Quote:
I probably should have stated it more clearly: it works on all
computers runing Win2000 server and newer: Wind2000 Server, WinXP and
Win2003.
I'm not sure about WinNT4. WinNT4 Terminal Server Edition should work.

Corné

On Tue, 21 Dec 2004 16:23:04 -0800, "chinn"
chinn@discussions.microsoft.com> wrote:

But can these be used to shutdown any win2k and Win2003
servers or it has to a Terminal Server Services.

Thanks,
"Corné Bogaarts" wrote:

There is a problem with Winlogon in Win2003 (MS KB 834100), that you
bump into if you try to use 'shutdown.exe' to reboot these servers.
The issue arises when a user connects to the server with Terminal
Server Client (mstsc.exe) while using the '/console'-option.

As far as I can tell we only had the problem if you would schedule the
shutdown, not if you use the shutdown command remotely from another
computer.

Before a colleague pointed me out this article I had been testing with
scheduling with 'schtasks', so i could use another user-account than
(local) System for the shutdown command. This didn't help.
Also giving commandline parameters for the 'Shutdown Event Tracker'
didn't help. As you noticed yourself, the /f-ption to 'force' a
shutdown didn't help either.

In the end I managed to work around the problem by using
'tsshutdn.exe' to reboot the computer. It's a shutdown-tool that's
available natively on Win2000 and Win2003 (and WinXP).
It seems actually to be directed at Terminal Servers (hence the 'ts'
in the name), but by default all Win2000 and up run TS to manage the
computer remotely or for remote assistance.


Corné

On Tue, 21 Dec 2004 06:49:05 -0800, "chinn"
chinn@discussions.microsoft.com> wrote:

Hello,
The below command is my batch file..

shutdown /r /t 20 /f

this is the AT command i use to schedule a reboot

at \\machine 16:02 "C:\restart.bat"
It schedules fine but it doesn't reboot it works fine on win2000
servers and
if you execute the batch file on the machine it works.

Did anybody experience this if so what was your resolution..


Thanks in advanvce..

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ:
http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including
my E-mail address anymore.


--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ:
http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including
my E-mail address anymore.
Back to top
Corné Bogaarts
Guest





Posted: Thu Dec 23, 2004 4:28 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

I know, I tested it, It didn't help.

Corné

On Wed, 22 Dec 2004 10:49:04 -0600, "aaron" <aaron@fake.net> wrote:

Quote:
might want to check out the new prefered commmand to schedule tasks.

http://www.microsoft.com/resources/documentation/WindowsServ/2003/standard/proddocs/en-us/Default.asp?url=/resources/documentation/WindowsServ/2003/standard/proddocs/en-us/schtasks.asp

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.
Back to top
Corné Bogaarts
Guest





Posted: Thu Dec 23, 2004 4:34 am    Post subject: Re: Using AT to schedule shutdown.exe to reboot win2003 mach Reply with quote

Didn't work on many of our Win2003 servers.
The point is that people (ie Administators) connect with 'MSTSC
/console'. When you log of correctly and you then schedule a reboot,
you run into a bug in Winlogon.exe (MS KB 834100).

As long as you don't use '/console' there's no problem. And from my
experience, if you use 'shutdown' to reboot a server remotely, instead
of scheduling a reboot-task on such a server, there's no problem
either.

Corné

On Wed, 22 Dec 2004 10:51:21 -0600, "aaron" <aaron@fake.net> wrote:

Quote:
Here is what I use, works fine on all my servers.

shutdown.exe /L /R /Y /C

--- --- --- --- --- --- ---
Most answers can be found in the Schedule+ FAQ: http://www.xs4all.nl/~bogaarts/schdmenu.htm.
Please reply to the newsgroup. For reasons of Spam, I won't be including my E-mail address anymore.
Back to top
 
Post new topic   Reply to topic    Windows Server Forum Index -> Programming All times are GMT
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




New Topics Powered by phpBB