#!/bin/bash

IP=1.2.3.4
while true; do
echo "**********************************************">>/root/ping_and_time.log
echo `date +%y-%m-%d-%H:%M:%S` >>/root/ping_and_time.log
ping -c 5  $IP >>/root/ping_and_time.log
echo "----------------------------------------------">>/root/ping_and_time.log
sleep 20
done

 

相关文章:

  • 2022-02-22
  • 2021-12-01
  • 2021-12-14
  • 2022-12-23
  • 2022-12-23
  • 2021-08-02
  • 2021-08-29
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-05-09
  • 2021-10-13
  • 2021-05-31
  • 2022-01-17
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案