An open API service indexing awesome lists of open source software.

https://github.com/franckferman/fix_wsl2_networking

Solve connection problems related to WSL2.
https://github.com/franckferman/fix_wsl2_networking

bash-prompt bash-scripts debian-linux dns networkingtool networks shell-scripting shell-scripts windows-10 windows-11 windows10 windows11 wsl-debian wsl-fix wsl-kali wsl-network wsl-ubuntu wsl2 wsl2-fix wsl2-network

Last synced: 10 months ago
JSON representation

Solve connection problems related to WSL2.

Awesome Lists containing this project

README

          

[![Contributors][contributors-shield]](https://github.com/franckferman/fix_wsl2_networking/graphs/contributors)
[![Stargazers][stars-shield]](https://github.com/franckferman/fix_wsl2_networking/stargazers)
[![License][license-shield]](https://github.com/franckferman/fix_wsl2_networking/blob/stable/LICENSE)


banner-fix_wsl2_networking

fix_wsl2_networking



Solve connection problems related to WSL2.


## ๐Ÿ“œ Table of Contents

Click to collapse/expand


  1. ๐Ÿ“– About

  2. ๐ŸŽฎ Getting Started

  3. ๐Ÿ“œ License

  4. ๐Ÿ“ž Contact

## ๐Ÿ“– About

This script provides a permanent fix for a persistent issue affecting WSL2 users on various Linux distributions, including Debian, Ubuntu, and Kali.

Many users attempt temporary configuration tweaks, only to find the problem recurring. This script eliminates the hassle by offering a reliable, long-term solution that works seamlessly.

If you've been struggling with this issue, or know someone who is, this script is the definitive fix you've been looking for.

### Tested On

This script has been successfully tested on multiple WSL2 environments, including:

* - [x] [Debian](https://www.microsoft.com/en-us/p/debian/9msvkqc78pk6)
* - [x] [Ubuntu](https://www.microsoft.com/en-us/p/ubuntu/9pdxgncfsczv)
* - [x] [Kali Linux](https://www.microsoft.com/en-us/p/kali-linux/9pkr34tncv07)

(back to top)

## ๐ŸŽฎ Getting Started

This repository is dedicated to fixing Internet connectivity issues in WSL2 when using a Linux distribution.

๐Ÿ“Œ Note: This guide does not cover WSL2 installation or setupโ€”only the networking fix.

My goal is to provide a reliable and efficient solution to help WSL2 users restore network connectivity and optimize their workflow.

### Prerequisites

Download the script directly via PowerShell:

```PowerShell
Invoke-WebRequest -Uri "https://raw.githubusercontent.com/franckferman/fix_wsl2_networking/stable/fix_wsl2_networking.sh" -OutFile "C:\Users\$env:UserName\fix_wsl2_networking.sh"
```

## Usage

1๏ธโƒฃ Move & execute the script from your Linux terminal in WSL2:

```sh
cd ~&&mv /mnt/c/Users/Your_Windows_UserName/fix_wsl2_networking.sh .&&chmod +x ./fix_wsl2_networking.sh&&sudo ./fix_wsl2_networking.sh
```

2๏ธโƒฃ Once the script completes, your connectivity issues should be resolved.

(back to top)

## ๐Ÿ“œ License

This project is licensed under the GNU Affero General Public License, Version 3.0. For more details, please refer to the LICENSE file in the repository: [Read the license on GitHub](https://github.com/franckferman/fix_wsl2_networking/blob/stable/LICENSE)

(back to top)

## ๐Ÿ“ž Contact

[![ProtonMail][protonmail-shield]](mailto:contact@franckferman.fr) [![LinkedIn][linkedin-shield]](https://www.linkedin.com/in/franckferman)

(back to top)

[contributors-shield]: https://img.shields.io/github/contributors/franckferman/fix_wsl2_networking.svg?style=for-the-badge
[contributors-url]: https://github.com/franckferman/fix_wsl2_networking/graphs/contributors
[stars-shield]: https://img.shields.io/github/stars/franckferman/fix_wsl2_networking.svg?style=for-the-badge
[stars-url]: https://github.com/franckferman/fix_wsl2_networking/stargazers
[license-shield]: https://img.shields.io/github/license/franckferman/fix_wsl2_networking.svg?style=for-the-badge
[license-url]: https://github.com/franckferman/fix_wsl2_networking/blob/stable/LICENSE
[protonmail-shield]: https://img.shields.io/badge/ProtonMail-8B89CC?style=for-the-badge&logo=protonmail&logoColor=blueviolet
[linkedin-shield]: https://img.shields.io/badge/-LinkedIn-black.svg?style=for-the-badge&logo=linkedin&colorB=blue