@Bright-Nnadi I understand. I followed the steps below and it works fine for me, I hope that will help you too.
- Installation steps :
Install ADB for windows
Install adb for ubuntu.
Check the version on both systems. On ubuntu, if using apt will install an older version than Windows, so should install it via platform-tools provided by Android studio
For Using ADB follow the steps below:
a) Run PowerShell in Admin mode, and go to the folder where ADB is located
There tape the command below:
.\adb.exe -a -P 5037 nodaemon server
That should connect and show the devices:
adb.exe I 02-28 17:55:47 13580 13948 adb.cpp:171] c6f37030: already offline
N.B.: The first time we run it, it will open a security window to give it access through the Firewall. Select the both, local and public network. It is needed to access the device through WSL (see step below).
Into another PowerShell window can connect to the device via .\adb.exe shell
b) on Ubuntu client :
Take the IP address of the WSL from the windows station:
ifconfig -> for me is something like 172.23.0.1 …
Look into the /etc/resolv.conf => there should be the address below, if not change it to this one
Run the command:
adb -H 172.23.0.1 -P 5037 devices
That should allow you to connect to adb device from Ubuntu client on Windows.