我尝试在perl中从shell脚本中获取rtt结果(如149.982/150.125/150.280/0.265 ms ),现在ping.sh可以从shell脚本中检索到rtt结果,但是如何返回结果以及如何从perl中的shell脚本中获取返回结果?##how to get the rtt results from ping.sh ???}getrtt() if ping $ip -c 5 -
我正在写一个石墨/钻石收集器测量网络延迟。具体来说,它应该测量打开到远程服务器上的端口的连接所需的时间。它需要通过脚本工作,即键盘上没有人以交互方式运行。time telnet --close-connection-immediately-after-established somehost.somedomain.com 1234
Connected to somehost.somedomain.com.
Escape character is