Not daily, but sometimes we need to ping destination computer IP or Computer name with time stamp and export ping results with time stamp to text or csv so that we can monitor it later on or troubleshoot if there is any issue.
So we can do in CMD or PowerShell. We have provided here solution in PowerShell and you can customize it as per your requirement.
Step 1-
Open Windows PowerShell as Administrator and type below command to record your PowerShell in text fileping.exe -t google.com|Foreach{"{0} - {1}" -f (Get-Date),$_} >> c:\Ping_result.txt
Change “google.com” as per your destination computer or website and “C:/Ping_result.txt” as per your local computer location
See below for your reference;
Step 2-
This will start saving your ping result to text file “C:/Ping_result.txt”
Cheers! Check you txt file for ping result with time stamp.