mirror of https://github.com/CrimsonTome/tldr.git
28 lines
603 B
Markdown
28 lines
603 B
Markdown
|
# ping
|
|||
|
|
|||
|
> 向网络主机发送 ICMP 回显请求数据包.
|
|||
|
|
|||
|
- Ping 指定的主机:
|
|||
|
|
|||
|
`ping {{主机}}`
|
|||
|
|
|||
|
- 对主机执行指定定次数的 ping 操作:
|
|||
|
|
|||
|
`ping -c {{次数}} {{主机}}`
|
|||
|
|
|||
|
- ping `主机` ,指定请求之间的间隔(以`秒`为单位)(默认为1秒):
|
|||
|
|
|||
|
`ping -i {{秒}} {{主机}}`
|
|||
|
|
|||
|
- Ping `主机`,但不尝试查找地址的符号名:
|
|||
|
|
|||
|
`ping -n {{主机}}`
|
|||
|
|
|||
|
- ping `主机` 并在收到数据包时响铃(如果您的终端支持):
|
|||
|
|
|||
|
`ping -a {{主机}}`
|
|||
|
|
|||
|
- ping `主机` 并打印接收数据包的时间(此选项是Apple的附加项):
|
|||
|
|
|||
|
`ping --apple-time {{主机}}`
|