From 227f11dbab1292b669c638c72dce65723b3bea62 Mon Sep 17 00:00:00 2001 From: Blue Date: Mon, 28 Mar 2022 20:12:22 +0000 Subject: [PATCH] Update networking.bat for store WSL (#8132) --- diagnostics/networking.bat | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/diagnostics/networking.bat b/diagnostics/networking.bat index 29295903..2d6ee0fb 100644 --- a/diagnostics/networking.bat +++ b/diagnostics/networking.bat @@ -8,6 +8,10 @@ net session >nul 2>&1 || goto :admin if not exist wsl_networking.wprp (echo wsl_networking.wprp not found && exit /b 1) if not exist networking.sh (echo networking.sh not found && exit /b 1) +:: Capture the store WSL version +echo "WSL version (Might be help text if store WSL is not installed):" +wsl.exe --version + :: List installed Windows features. echo Windows features: powershell.exe -NoProfile "Get-WindowsOptionalFeature -Online | ? State -eq Enabled | select FeatureName" @@ -25,7 +29,7 @@ echo Deleting HNS network powershell.exe -NoProfile "Get-HnsNetwork | Where-Object {$_.Name -eq 'WSL'} | Remove-HnsNetwork" :: Stop WSL. -net.exe stop LxssManager +net.exe stop WslService || net.exe stop LxssManager :: Start packet capture. powershell.exe -NoProfile "New-NetEventSession HnsPacketCapture -CaptureMode SaveToFile -LocalFilePath %cd%\\packets.etl" || goto :fail