Giter Site home page Giter Site logo

wsl2-custom-network's People

Contributors

skorhone avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

wsl2-custom-network's Issues

You perhaps helped solved a WSL2 Corporate-Enterprise VPN Clash WSL2 Broken Subnet Network after 13 years

Design Flaws Both in WSL2 Broken Network Settings and in Windows Continues to Plague Corporate Developers

I have been using WSL2 for 1 year in an corporate/enterprise setting. I can't thank-you enough, perhaps got a lead on a solution for a BILLION DOLLAR T-REX LEVEL BUG that first came out a long time ago with WSL1. WSL2 could so easily have been a flagship app of Microsoft, but for networking it SUCKS so bad many bigger companies forbid WSL2 use, WSL2 networking just fails to ping network dies randomly. Many frustrated users who hold down real jobs get so mad with WSL2 teams programmers who then get "hurt feelings" this problems is for sure beyond "hurt feelings" ALREADY.

I am a key Linux developer right down to my code running on every mobile network.
So me coding a C++ fix for Microsoft's by far most ignored bug is hilarious!

I have tried about 30 different approaches to the fix but the way WSL2 configures networks is broken at the design level, the
design sucks. WSL1 and WSL2 teams have closed THOUSANDS OF BUG REPORTS, ALL 100% CRITICAL (not Major) and all UNFIXED. Yup thousands! So I comment on them closing it: "You are a genius, so glad you closed this bug as it therefor must be fixed magically with no code changes, you fixed a 13 year old CRITICAL bug."

The following bruit force and no intelligence script works RANDOMLY, but your one is intelligent.

echo "Restarting WSL Service"
wsl --shutdown
Restart-Service LxssManager
echo "Restarting Host Network Service"
Stop-Service -name "hns"
Start-Service -name "hns"
 echo "Restarting Hyper-V adapters"
Get-NetAdapter -IncludeHidden | Where-Object `
     {$_.InterfaceDescription.StartsWith('Hyper-V Virtual Switch Extension Adapter')} `
     | Disable-NetAdapter -Confirm:$False
 Get-NetAdapter -IncludeHidden | Where-Object `
     {$_.InterfaceDescription.StartsWith('Hyper-V Virtual Switch Extension Adapter')} `
     | Enable-NetAdapter -Confirm:$False

A primary symptom is if you manage to get WSL2 networks working the PC going to sleep breaks it but not other apps networks.

Sadly corporate/enterprise IT prevents PowerShell scripts from running even in admin mode in sensitive organisations (actually I
approve of PowerShell being blocked as it is UNTRUSTED) - but ironically you can cut and past scripts (your nice script) into ADMIN PowerShell directly and it works. Hence I'm taking your solution and coding it in C++ but also creating another tool that displays the network configs (for randomly working WSL2 enterprise networks that work 1 in 8 reboots - hitting by accident an authorised subnet). 7 out of those 8 reboots triggering major security alerts - YA WAY-TO-GO WSL2 and Microsoft for your MAD and RANDOM
network settings for WSL2 that violate security in a massive way that encourages IT to open the IP doors too wide to make buggy-wuggy-WSL2 work.

Windows applications work over the network just fine, but corporate/enterprise WSL2 Networks fail and it SUCKS!

Microsoft's most valued customers get this bug the most, and it's worse as IT prevent PowerShell scripts running even in admin mode.
Your PowerShell fix is based off of some C or C++ code from here and that is a nice start. So thank-you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.