The ADB commands in this paper are divided into three parts: adb 命令 , adb shell 命令 ,linux 命令
ADB command
Here are some of the most commonly used commands:
1. ADB connect remote connected Android device
2, ADB devices, get equipment list and equipment status
ADB get-state, getting the status of the device
Device: normal connection of devices
Offline: Connection unexpected, device not responding
Unknown: No device connected
3. ADB kill-server, end ADB service
4, ADB start-server, start the ADB service
5, ADB logcat, print the Android system log
6, ADB bugreport, print the output of Dumpsys, Dumpstate, Logcat, for analyzing errors
adb bugreport > d:\bugreport.log
7, adb install, installation application, overlay installation is using the-r option
8. ADB Uninstall, uninstall application,-K option, save data and cache directory when uninstalling
9. adb pull, copy files or folders on Android device to local
adb pull sdcard/pull.txt d:\
如果需要重命名为 rename.txt:adb pull sdcard/pull.txt d:\rename.txt
10, ADB push, push local files to Android device
adb push d:\push.txt sdcard/
11, ADB reboot, restart Android device
12, adb forward, redirect a port on the host to a port on the device
adb forward tcp:1314 tcp :8888 After executing this command, all messages sent to host port 1314 will be forwarded to the 8888 port on the Android device, so you can control the Android device remotely.
Android Common ADB Command summary