Disable remote computers in batches

Source: Internet
Author: User

Disable remote computers in batches
too many computers have been disabled before too many computers have been disabled

Windows XP has a powerful shutdown tool named shutdown. You can use this function to cancel a user, shut down a computer, or restart a computer on the Windows graphic operation interface. More importantly, you can use it to shut down or remotely shut down the computer at a specified time. This cannot be completed on the Windows graphic operation interface! If one day your computer is downloading a software, it will take 30 minutes to complete, but you have something to go out immediately, then you need to use the Timed Shutdown function; similarly, you have managed a small data center. It is very troublesome to shut down a server every day! You can solve this problem with shutdown without installing the client on each computer.Program!
The shutdown program is a Windows program and does not have this program in Windows 9x/2000. However, due to the basic nature of Windows 2000 and Windows XP, we can copy this shutdown.exe program to the winntsystem32 folder of windows for normal use, but Windows 9x does not work.
The specific shutdown format is:
Shutdown [-I |-L |-S |-r |-A] [-F] [-M computername] [-T XX] [-C "Comment"] [- d up: XX: yy]
The specific parameters are described as follows:
-I: displays the GUI, which must be the first option.
-L: Logout (cannot be used with option-m ).
-S: disable this computer.
-R: Disable and restart the computer.
-A: discard the system shutdown.
-M computername: shutdown, restart, and discard a remote computer.
-T xx: Set the timeout value to XX seconds.
-C "comment": Close comments (up to 127 characters ).
-F: the application that runs forcibly is disabled without warning.
-D[P]: XX: YY: reason for disablingCode(This item is generally not used ).

Timed Shutdown of Computer

1. we have learned how to use the shutdown command. If we want to shut down the local computer 60 minutes later, click the Start menu and select Run ", then, in the input box, enter:
Shutdown-s-t 3600 (see Figure 1)


After running, the system will immediately pop up a "system shutdown window": "The system is about to shut down. Please save the running work ......", There is also a shutdown countdown timer (see figure 2), which cannot be closed. When it reaches shutdown, the system will force shutdown.


2. If you want to cancel the Timed Shutdown during this period, you can enter the following in the "run" box:
Shutdown-
In this way, the shutdown will be canceled at the specified time, and the "system shutdown window" will disappear immediately. Easy!

Disable remote computer

Disabling a remote computer is a little more complex than shutting down a computer at a specified time. First of all, you must note that shutdown can only remotely shut down Windows 2000/XP computers, so the computers to be remotely shut down can only be Windows XP or Windows 2000 computers, windows 9x does not work on computers.
Because the default group policy of Windows 2000/XP system sets that only Members in the Administrator group have the right to remotely shut down the server, we need to change this setting, otherwise, identity authentication is required for each remote shutdown! The procedure is as follows:
(1) Click the "Start" menu, select "run", and enter "gpedit. MSC, and then click OK to open the Group Policy Editor ".
(2) In the left window of the "Group Policy Editor", choose "Computer Configuration> Windows Settings> Security Settings> Local Policies> User Rights Assignment" (see Figure 3 ).


(3) In the right window of "Group Policy Editor", select "Force Shutdown From Remote System", double-click, the pop-up dialog box shows that only "members in the Administrator group" have the right to remotely shut down the server. Click the "add user or group" button at the bottom of the dialog box, and enter: "Guest" (see Figure 4) and then click "OK". A "guest" user (see figure 5) is added to the "Force Shutdown From Remote System" attribute box ), click OK to complete the settings, so that the computer grants the guest group users the permission to "remotely close the computer.


(4) set all computers to be remotely disabled in the same way.
3. After the remote shutdown permission is set, you can truly experience the convenience of Remote Computer shutdown. If there are two hosts A and B in the LAN, We Need To Disable Machine B from machine a. Just click the Start Menu of machine A and select Run ", then enter (without line feed) in the input box ):
Shutdown-F-m
(Host B name or IP address)
Click "OK". The "system shutdown window" will pop up on machine B and shut down (the system will wait 20 seconds by default ), if you want to shut down the remote host after 60 minutes, you only need to add the Timed Shutdown parameter (no line feed ):
Shutdown-F-m
(Machine B's name or IP address)-T 3600
Other functions of the shutdown command can also be implemented on a remote host. If you are interested, try it on your own.

Disable remote computers in batches

ArticleAt this point, some may ask: "If I want to shut down more than one remote computer, but a batch of remote computers, I can't lose a command every time I close it, is there any good way?"
There is a solution, and it is very simple! We have introduced that shutdown has an I parameter, which must be the first option. It is used to display the GUI. We can use this GUI to disable remote computers in batches. In the "run" column, enter:
Shutdown-I


The system displays a graphical interface for the "remote shutdown dialog box" (see Figure 6). Click the "add" button in the upper-right corner to bring up the "add computing" button.
Enter the name of the computer to be shut down (see figure 7) in the input box. Press "OK" and the computer will be included in the list of computers to be shut down, add all the computers to be shut down, and then select "Shut Down" in "What do you want these computers to do" in the "remote shutdown dialog box ", add the time you want to delay to the "display warning time" of "alarm user this operation, finally, add the reason for shutdown in the "comment" box at the bottom (you can add it as needed) and press "OK" to shut down these computers. Is it easy! However, this method has a disadvantage: after shutdown, the system will not save the computer columns for this shutdown, that is, you will need to re-add all the computers when you want to shut down these computers for the second time, inconvenient. If you need to shut down a large number of computers, it is recommended to write a. BAT file with the following content:
Shutdown-F-M server1
Shutdown-F-M server2
Shutdown-F-M server3
......


You can change it as needed, so you only need to run the. BAT file every time you shut down. Of course, if you are interested, you can compile a small program with detailed shutdown options based on shutdown, which is more convenient.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.