MustardChef / WSABuilds

Run Windows Subsystem For Android on your Windows 10 and Windows 11 PC using prebuilt binaries with Google Play Store (MindTheGapps) and/or Magisk or KernelSU (root solutions) built in.
GNU Affero General Public License v3.0
8.28k stars 1.39k forks source link

[Solved] Can WSL2 run adb to connect to WSA? #449

Closed Schefflin closed 1 month ago

Schefflin commented 2 months ago

I want to use WSL Android-sdk-tools to work on WSA. However, under WSL, only "eth0" from itself is listed, no other vEthernet can be found.

Schefflin commented 1 month ago

On Windows11 23H2(make sure you complete all updates), supposing you have installed WSL2 and run the distribution, open "WSL Settings--Network" and choose "Mirrored", and then exit and restart your PC. When your WSA is running, press "ip addr show" on WSL to check it, if you see the result like this: 屏幕截图 2024-10-19 103254 "adb start-server" (be patient to wait for few minutes) "adb connect 127.0.0.1:58526" Enjoy!