Created
September 1, 2016 08:14
-
-
Save dhcgn/1610db75d2e2f02e7e4b0c089a4ee584 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gci C:\inetpub\logs\LogFiles | # Get all sites | |
%{ gci $_.FullName | Sort-Object LastWriteTime | select -Last 1 } | # Get the last log file from each site | |
?{$_.LastWriteTime -gt (Get-Date).Date} | # only files from today | |
Get-Content -Tail 5 | # get the last lines | |
Select-String -Pattern 'POST' | # only method POST | |
Sort-Object # sort ASC |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment