File-1 = ping_google.bat
ping google.com -t
File-2 = ping_loop.bat[This script will try to ping google.com 30 times per second]
@echo off
cls
Set Sleep=0
:start
if %Sleep% == 30 ( goto end )
start /b ping_google.bat
echo This is a loop
Set /A Sleep+=1
echo %Sleep%
goto start
:end
echo "am 30 now"
pause
###########################################################
Below sample can be used to send exactly 1000 pkts from the PC:
File-1 = ping_50.bat
ping 123.123.123.123 -l 1400 -w 500 -n 50
File-2 =
@echo off
cls
Set Sleep=0
:start
if %Sleep% == 20 (goto end)
start /b ping_50.bat
echo This is a loop
Set /A Sleep+=1
echo %Sleep%
goto start
:end
echo "am 30 now"
pause
ping google.com -t
File-2 = ping_loop.bat[This script will try to ping google.com 30 times per second]
@echo off
cls
Set Sleep=0
:start
if %Sleep% == 30 ( goto end )
start /b ping_google.bat
echo This is a loop
Set /A Sleep+=1
echo %Sleep%
goto start
:end
echo "am 30 now"
pause
###########################################################
Below sample can be used to send exactly 1000 pkts from the PC:
File-1 = ping_50.bat
ping 123.123.123.123 -l 1400 -w 500 -n 50
File-2 =
@echo off
cls
Set Sleep=0
:start
if %Sleep% == 20 (goto end)
start /b ping_50.bat
echo This is a loop
Set /A Sleep+=1
echo %Sleep%
goto start
:end
echo "am 30 now"
pause
No comments:
Post a Comment