Tailing a log in Windows with Powershell

by Sep 23, 2025IT Tips0 comments

# just show the last 20 lines and exit
Get-Content MyLogFile.log -Tail 20

# show last 20 lines and follow as content is appended to the log 
Get-Content MyLogFile.log -Tail 20 -Wait

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

The reCAPTCHA verification period has expired. Please reload the page.