Hot Article
- Centos7 closes and restarts the system firewall and opens firewall ports
- How IID server uses Xshell to connect to Linux (centos) server
- BT panel forgets the background login URL, and the solution to the security entrance verification failure
- The php domain name points to ip, how to use the specified ip address to access a server in the url request domain name in curl mode
- How to purchase a dedicated server
- Error connecting to MySQL: Cant connect to MySQL server (10060)
windows timer task settings (with shutdown restart command)
- Author:Sven
- Category:Server Maintain
- Release Time:2023-03-06
The Task Scheduler for Windows allows you to add scheduled tasks, set the task start time and the interval of execution to achieve automatic execution of the application. For example, to achieve common functions such as timed reboot and shutdown. How to use refer to the following steps
1. Create a new text file, change the file suffix to bat, and then add the following code
shutdown -r -f -t 0
The purpose of this command is to immediately force a reboot of the machine. Click Save As in the file, select all types, and the file name is "auto-reboot.bat".
# Note: The usage of the shutdown command is described below.
# -r: Shutdown and restart the computer.
# -f: Forcibly closes the running application without forewarning the user. When a value greater than 0 is specified for the -t parameter, the -f parameter is used by default.
# -t xxx: Sets the timeout before shutdown to xxx seconds, valid range is 0-315360000 (10 years), default value is 30.
2. Expand Task Scheduler Select Microsoft and click Create Basic Task.
3、Configure the task wizard and select the task trigger time.
4、Create the basic task to complete.
5、Click Run to test. (It will restart immediately)
Translated with www.DeepL.com/Translator (free version)
related topic
- How to fix 403forbidden (detailed solution)
- What should I do if I lose connection to the game server of Legend M international service? (Detailed solution)
- Centos7 closes and restarts the system firewall and opens firewall ports
- inuxfind-name fuzzy query
- IDGlobal teaches you to disable ICMP protocol on CentOS
- How to change the password of Windows server 2008 server?