Ping all addresses in network, windows

前端 未结 11 1710
庸人自扰
庸人自扰 2021-01-30 00:14

Is it possible in windows cmd line to check all of the network addresses (with ping or similar) to see which ones are taken/ have active devices:

ie. something that does

11条回答
  •  广开言路
    2021-01-30 00:54

    for /l %%a in (254, -1, 1) do ( 
        for /l %%b in (1, 1, 254) do (
            for %%c in (20, 168) do (
                for %%e in (172, 192) do (
                    ping /n 1 %%e.%%c.%%b.%%a>>ping.txt
                )
            )
        )
    )
    pause>nul
    

提交回复
热议问题