Created
January 19, 2017 10:03
-
-
Save lukeplausin/bb08937980b997bb524c7cd2fcf79aa7 to your computer and use it in GitHub Desktop.
What is DFSR doing? Short script to tail the DFS-R logs in windows debug log.
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
$WorkingDir = "$HOME/Documents/dfsr-logs" | |
new-alias 7z "C:\Program Files\7-zip\7z.exe" | |
cp C:/Windows/debug/Dfsr00999.log.gz $WorkingDir | |
rm -recurse -force $WorkingDir/extracted | |
7z e $WorkingDir/Dfsr00999.log.gz "-o$WorkingDir\extracted" | |
# gc $workingdir\extracted\Dfsr00999.log | sls "^[^+]" | |
echo "Last 60 lines of DFSR log" | |
gc $workingdir/extracted/Dfsr00999.log -tail 60 | |
echo "First 10 entries" | |
gc $workingdir/extracted/Dfsr00999.log | sls "^[^+]" | select-object -first 10 | |
echo "First 10 GVSN file IDs" | |
gc $workingdir/extracted/Dfsr00999.log | sls ".*gvsn.*" | Select-Object -first 10 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment