Forum Home
Press F1
 
Thread ID: 106538 2010-01-12 23:45:00 need someway to shutdown all desktop machines but not server nedkelly (9059) Press F1
Post ID Timestamp Content User
848168 2010-01-13 05:01:00 Have a read of This article (maximumpcguides.com) - down the botom may be of interect - also found This software (www.filebuzz.com) JOC not free, but I dont have time to try it currently. wainuitech (129)
848169 2010-01-13 05:26:00 what would be the information in the txt file?
just the machine names (yes all of them) one per line eg.

pc1
pc2
pc3
etc.

as for the mac's all bets are off :)
fred_fish (15241)
848170 2010-01-13 05:58:00 macs are already done. One image for each type of mac with all settings and software installed. And told to shut down at 6pm nedkelly (9059)
848171 2010-01-13 06:01:00 So fred_fish do I just copy the code you put into your previous post into a notepad doc and save it with a .bat extension?
Also where would I save the machinelist.txt file?
nedkelly (9059)
848172 2010-01-13 06:30:00 So fred_fish do I just copy the code you put into your previous post into a notepad doc and save it with a .bat extension?
Yup. Or .cmd

Also where would I save the machinelist.txt file?
Same place as the batch file, or else you need the path to it in the command.

If all your targets are in a DHCP pool that excludes the servers I would lean towards the "for /l" option as it will just cycle through all the IP's.
Saves making (and updating) a target list, and the Mac's will ignore the command anyway.
fred_fish (15241)
848173 2010-01-13 07:01:00 yeah class b address pool but the servers are in the pool as well so will probably do the name list. And being a school they are all perfectly numbered. nedkelly (9059)
848174 2010-01-13 07:17:00 If they are numbered you could still use the for /l option with the placeholder as a substring in the machine name rather than ip.
But it really depends on your naming scheme, and padding may be an issue (although should be easy to work around)
fred_fish (15241)
848175 2010-01-13 07:34:00 naming scheme: three letters (same for all) then number nedkelly (9059)
848176 2010-01-13 22:30:00 for /l %%a in (1,1,9) do shutdown -f -s -m \\abc00%%a
for /l %%a in (10,1,99) do shutdown -f -s -m \\abc0%%a
for /l %%a in (100,1,999) do shutdown -f -s -m \\abc%%a
or combinations thereof :)
fred_fish (15241)
848177 2010-01-14 03:14:00 hey fred_fish, just wondering what the numbers in the code are for and what do they do? nedkelly (9059)
1 2 3