1. 程式人生 > >adb shell error: more than one device and emulator

adb shell error: more than one device and emulator

今天我在cmd命令列中執行ADB指令時,報錯。
C:\Users\gaojs>adb shell
error: more than one device and emulator

碰到這種情況,首先要查一下,是不是真的有多個裝置或模擬器。
C:\Users\gaojs>adb devices
List of devices attached
HAOZ5HPF5LHUSCCM        unauthorized
127.0.0.1:26944 device
發現還真是多個裝置,那就需要為ADB命令指定裝置的序列號了。
C:\Users\gaojs>adb -s 127.0.0.1:26944 shell

 

 

具體操作流程如下是:

C:\Users\Administrator>adb shell
error: more than one device/emulator

C:\Users\Administrator>adb devices
List of devices attached
HAOZ5HPF5LHUSCCM        unauthorized
127.0.0.1:26944 device


C:\Users\Administrator>adb -s 127.0.0.1:26944 shell

[email protected]:/ #