Re: Shutdown computers

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



We are trying to implement the same sollution.
Wa also want to remotely and automaticaly shutdown our Windows XP computers
in our Windows 2003 Domain (all clients run WXP SP2).

I would realy like to use your sollution, but have no idea about VB
scripting. Do you have a working VBS sample that does the trick?

Grx,
Joris

"MoiToo" wrote:

Are the computers all using XP/2000/NT? If so, look at the
shutdown.exe -s -f -t 120 -c "GET OFF YOU LAZY BUM" -m \\COMPUTERNAME
command, saved as a CMD.
Create a VBS, with a for/next loop reading all computer names from AD.
Launch (externally) the cmd file for each computer.

I would launch it externally, so that if a computer is slow, or unreachable
(off?), there is no wait time - you have almost simultaneously launched 500+
shutdown commands. Remember not to launch many more than 1500 at a time...

The exact answer you wanted is that WMI is not able to perform this task.
You could try using VB and read up on SE_SHUTDOWN_NAME_PRIVELAGE - but the
inbuilt shutdown command is much easier, and still clean.


"Hen_ro" <Hen_ro@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:3187AFE7-0FD0-4AB9-944E-628175DE5932@xxxxxxxxxxxxxxxx
I have a problem in our network with 500+ computsers studendts dont
shutdown
ther computers at the en off the day.

I have a script that shut downs the computer

strComputer = "."
Set objWMIService =
GetObject("winmgmts:{impersonationLevel=impersonate,(Shutdown)}\\" &
strComputer & "\root\cimv2")

Set colOperatingSystems = objWMIService.ExecQuery ("Select * from
Win32_OperatingSystem")

For Each objOperatingSystem in colOperatingSystems
objOperatingSystem.Win32Shutdown(1)
Next

now the next thing what i want is to use this with group policy manegment
to
give this with a startup script for every computer to shutdown a special
time
that i want and warns the students(a timer)that the computer is gonna
shutdown.
so even there is nobody behind that computer the computer will auto
shutdown
when i want.
is there a way to put a time or timer and a warning in this script??

hen_ro



.



Relevant Pages

  • Re: %windir%...scriptsshutdown Q
    ... MS-MVP Windows Shell/User ... Overview of Logon, Logoff, Startup, and Shutdown Scripts in Windows ... How To Assign a Logon Script to a Profile for a Local User in Windows ... When you use Group Policy to add a startup script... ...
    (microsoft.public.windowsxp.general)
  • RE: Finetuning: Remote Shutdown with WMI, some errors occur.
    ... Also we would like that a workstation that's locked is also shutdown by this ... script to shutdown all approx. ... Dim strBase, strFilter, strAttributes, strQuery, objRecordSet ... Const OpenAsDefault = -2 ...
    (microsoft.public.windows.server.scripting)
  • Re: VBscript that restart the domain comptuer
    ... If you have a shutdown script that cleans up the profiles, ... permissions can restart all computers in a list remotely. ... I have already VB script I ...
    (microsoft.public.windows.server.active_directory)
  • Re: Closing down Windows with a script
    ... For suggestions as to possible fixes for the underlying problem, ... but shutdown issues for all versions of Windows ... > write even a simple script to do this. ...
    (microsoft.public.scripting.wsh)
  • Re: Shutdown Scripts
    ... Instead of using a shutdown script. ... The Windows 2000 Pro PC just shuts down. ... > As per other instructions, you would be better off scheduling the defrag> script which, at the end, initiates shutdown. ...
    (microsoft.public.windows.server.active_directory)