There is no formal Sleep for calling after a good batch processing. Sometimes, it is really boring.
1. Method 1:
Ping 1.1.1.1 to simulate
It is difficult to find an answer (called an answer because it is labeled as answer) from stackoverflow:
Ping 1.1.1.1-n 1-w 60000> nul
This indicates that sleep is performed for 60 seconds.
Is that true? It is based on the assumption that 1.1.1.1 will never be pinged by the target machine. However, I encountered a strange incident. On a test machine, I can ping the server directly:
Pinging 1.1.1.1 with 32 bytes of data:
Reply from 1.1.1.1: bytes = 32 time <1 ms TTL = 60
Reply from 1.1.1.1: bytes = 32 time <1 ms TTL = 60
Reply from 1.1.1.1: bytes = 32 time = 6 ms TTL = 60
Reply from 1.1.1.1: bytes = 32 time <1 ms TTL = 60
Ping statistics for 1.1.1.1:
Packets: Sent = 4, stored ED = 4, Lost = 0 (0% loss ),
Approximate round trip times in milli-seconds:
Minimum = 0 ms, Maximum = 6 ms, Average = 1 ms
Therefore, this method is unreliable.
2. ping is still used for simulation,
See the following bat:
@echo offecho "emulate sleep......"call :wait_ext1 60echo "60 seconds waited...."goto :eof:wait_ext1@ping 127.0.0.1 -n 2 -w 1000 > nul@ping 127.0.0.1 -n %1% -w 1000> nul
This indicates that sleep takes about 60 seconds.
Of course, you can also rename the wait_ext1 part to a separate batch for calling.
3. It seems that 2003 has another resource kitpackage downloaded, with sleep.exe on its side.
(Why not release it ?)
Http://malektips.com/xp_dos_0002.html
Sometimes I hate Windows for batch processing.