一、
問題:css
$ adb devices List of devices attached R8V5T15B27002337 no permissions (verify udev rules); see [http://developer.android.com/tools/device.html]
2、問題的緣由及解決
由於ubuntu這樣的系統都是默認以非root身份在運行的,要使用usb調試,須要sudo支持
使用lsusb命令列出usb鏈接的設備,如;
$ lsusb
Bus 004 Device 004: ID 03f0:231d Hewlett-Packard 4 GB Flash Drive
Bus 004 Device 003: ID 0461:4dce Primax Electronics, Ltd
Bus 004 Device 008: ID 0fce:6193 Sony Ericsson Mobile Communications AB
Bus 004 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 004 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 005: ID 04ca:0061 Lite-On Technology Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 003: ID 138a:003c Validity Sensors, Inc. VFS471 Fingerprint Reader
Bus 003 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
列表中Bus 004 Device 008: ID 0fce:6193 Sony Ericsson Mobile Communications AB,爲所鏈接的android設備的信息,記錄一下,id爲ofce(基於上全部的sony device都是這個ID)
sudo gedit /etc/udev/rules.d/51-android.rules,在打開的51-android.rules
加入一下內容:
SUBSYSTEM=="usb", ATTR{idVendor}=="0fce", MODE="0666", GROUP="plugdev"
OR:
SUBSYSTEM=="usb", ATTRS{idVendor}=="0fce
", ATTRS{idProduct}=="6193",MODE="0666"
而後修改udev的權限,並重啓
$sudo chmod a+rx /etc/udev/rules.d/51-android.rules
$sudo service udev restart
51-android.rules0fce51-android.rules
51-android.rules
重啓 adb server, (拔掉usb從新連上再執行):adb kill-serveradb devicesadb rootRefer to: http://www.cnblogs.com/cat-lee/archive/2011/07/09/2101718.html