ping监控采集一段时间的数据

命令:ping www.baidu.com | awk '{ print $0" "strftime("%Y-%m-%d %H:%M:%S",systime()) }' >>/tmp/baidu.log &

持续ping并将结果记录到日志

 

 输出的结果会记录到/tmp/baidu.log 中,每秒钟新增一条ping记录。

相关文章:

  • 2021-08-25
  • 2021-08-07
  • 2021-12-02
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-22
  • 2021-08-29
猜你喜欢
  • 2022-12-23
  • 2021-06-10
  • 2021-06-18
  • 2021-11-05
  • 2021-09-28
  • 2021-07-30
  • 2021-10-15
相关资源
相似解决方案