Mombu the Microsoft Forum sponsored links

Go Back   Mombu the Microsoft Forum > Microsoft > Windows 2000 Server (TECHNET) > Shutdown script doesnt work
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 10th August 05:31
tony liu
External User
 
Posts: 1
Default Shutdown script doesnt work



Hello,
Configuring it as a startup script works. Works too as a logoff script. But
not working for shuttdown script. My script is as follows:


Dim oShell
Set oShell = CreateObject("Wscript.Shell")

Set objEmail = CreateObject("CDO.Message")

objEmail.From = "tliu@superb.net"
objEmail.To = "tliu@superb.net"
objEmail.Subject = oShell.ExpandEnvironmentStrings("is shutting down by " )
objEmail.Textbody = now


objEmail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
objEmail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserver") = _
"smail2.superb.net"
objEmail.Configuration.Fields.Item _
("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
objEmail.Configuration.Fields.Update
objEmail.Send

Which configuration should I check?

Thanks

Tony
  Reply With Quote


  sponsored links


2 10th August 15:30
External User
External User
 
Posts: 1
Default Shutdown script doesnt work



Hi,

Try Shutdown.exe or restart.vbs (available from MS)

Cheers,
Lara
  Reply With Quote
3 10th August 21:25
tony liu
External User
 
Posts: 1
Default Shutdown script doesnt work


Hello,
I'm using shutdown -r -t 0 to reboot the server, shutdown script in GPO not
working. Oneday suddently the server was totally shutdown(not reboot), the
scirpt works. I just want to know the shutdown script in GPO running or not
when I reboot a server.

Thanks
  Reply With Quote
4 10th August 21:25
tony liu
External User
 
Posts: 1
Default Shutdown script doesnt work


Sorry, it seems working when I shutdown by clicking Start->Shutdown. If I
use shutdown -r -t 0, script doesn't run. I'm keeping on trying some
different options of shutdown.exe to see if I have a luck.

Thanks
  Reply With Quote
5 11th August 06:04
External User
External User
 
Posts: 1
Default Shutdown script doesnt work


Hi,

I use the shutdown.exe all the time in a Script but I don't use a GPO,
instead I schedule it in scheduled tasks. As Shutdown.exe will let you
remotely shutdown and startup computers using the -m command you can do it
remotely. I shutdown all my computers every night with it.

Remember that with Server 2003 you HAVE to specify a reason so you will need
to add the reason code and the explanation to the script or it won't work
with server 2003. Do shutdown.exe /? at the command prompt on Server 2003 to
get the options. I don't have the server in front of me so I cannot remember
the exact ones.

Cheers,
Lara
  Reply With Quote


  sponsored links


Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666