scrcpy
scrcpy copied to clipboard
Snap: adb server version (39) doesn't match this client (41)
Environment
- OS: Ubuntu 18.04
- scrcpy version: 1.16
- installation method: snap
- device model: Pixel 4a
- Android version: 11
Describe the bug
When I run scrcpy:
adb server version (39) doesn't match this client (41); killing...
* daemon started successfully
connected to 192.168.50.18:5555
eater $INFO: scrcpy 1.16 <https://github.com/Genymobile/scrcpy>
adb server version (41) doesn't match this client (39); killing...
* daemon started successfully
adb: error: failed to get feature set: no devices/emulators found
ERROR: "adb push" returned with value 1
I think because:
$ /snap/scrcpy/current/usr/bin/adb --version
Android Debug Bridge version 1.0.39
Version 1:8.1.0+r23-5~18.04
Installed as /snap/scrcpy/256/usr/lib/android-sdk/platform-tools/adb
https://github.com/Genymobile/scrcpy/blob/master/FAQ.md#conflicts-between-adb-versions
ADB=$(which adb) scrcpy
Sorry, github web is being weird but I meant to include that that gives a different error:
$ADB=$(which adb) scrcpy
INFO: scrcpy 1.16 <https://github.com/Genymobile/scrcpy>
exec: No such file or directory
ERROR: Command not found: [/usr/local/bin/androidtools/platform-tools/adb], [push], [/usr/local/share/scrcpy/scrcpy-server], [/data/local/tmp/scrcpy-server.jar]
ERROR: (make 'adb' accessible from your PATH or define its fullpath in the ADB environment variable)
INFO: You may install 'adb' by "apt install adb"
ERROR: Could not execute "adb push"
What is the result of:
/usr/local/bin/androidtools/platform-tools/adb devices
?
List of devices attached
192.168.50.18:5555 device
So for some reason snap can't see your host filesystem to use your adb.
Try to use a non-snap version (= build it).
Yup, building it works (that's how I've been using scrcpy till now, it's great)
I'm having this very same problem.
scrcpy
INFO: scrcpy 1.14 <https://github.com/Genymobile/scrcpy>
adb: error: failed to get feature set: no devices/emulators found
ERROR: "adb push" returned with value 1
sudo scrcpy
INFO: scrcpy 1.14 <https://github.com/Genymobile/scrcpy>
adb server version (41) doesn't match this client (39); killing...
* daemon started successfully
adb: error: failed to get feature set: no devices/emulators found
ERROR: "adb push" returned with value 1
ADB=$(which adb) scrcpy
INFO: scrcpy 1.14 <https://github.com/Genymobile/scrcpy>
adb server version (39) doesn't match this client (41); killing...
* daemon started successfully
adb: error: failed to get feature set: no devices/emulators found
ERROR: "adb push" returned with value 1
sudo ADB=$(which adb) scrcpy
INFO: scrcpy 1.14 <https://github.com/Genymobile/scrcpy>
adb: error: failed to get feature set: no devices/emulators found
ERROR: "adb push" returned with value 1
Ubuntu 20.10 and Android-Studio downloaded from a repo (not snap) http://ppa.launchpad.net/maarten-fonville/android-studio/ubuntu/
this issue is caused by two versions of adb installed inthe system.. i think their package installs the ubuntu apt adb version and saves it in /usr/bin/adb
then we have /home/fabrizio/Android/Sdk/platform-tools/adb and the version from /usr/bin/adb causes this error
I removed such version and error went away
this issue is caused by two versions of adb installed inthe system.. i think their package installs the ubuntu apt adb version and saves it in /usr/bin/adb
then we have /home/fabrizio/Android/Sdk/platform-tools/adb and the version from /usr/bin/adb causes this error
I removed such version and error went away
It works. Thank you so much @fabriziobertoglio1987 :)
THIS WILL REALLY HELP YOU (almost 90% of the time this might be the problem)
-
Download the latest version of ADB from the official Android developer website:
[https://developer.android.com/studio/releases/platform-tools]
-
Extract the contents of the ADB ZIP file to a directory on your system, such as ~/Tools.
-
Add the directory containing the ADB binary to your PATH environment variable by adding the following line to your .bashrc file:
`export PATH=$PATH:/path/to/adb-file-just-downloaded-and-extracted/` -
Reload the .bashrc file by running the following command:
. ~/.bashrc -
Try running
scrcpyagain and see if the error message goes away.