This paper mainly introduces the commonly used commands and common directory of the ADB .
1. Common command of ADB
The ADB devices lists all connected Android devices.
The following command is for a single devices, if there are multiple devices, the following command will need to change ADB to Adb-s deviceId
The ADB shell enters the devices command line mode and goes to command line mode, which is the Linux command line.
ADB shell command enters devices command-line mode and runs command
ADB shell am start-n <package>/<package>.<activity>adb Command launcher
ADB shell am start-d-N <package>/<package>.<activity>adb command startup program debug mode
ADB push <local> <remote> transfer local files to device, such as install system APK, ADB push a.apk/system/app/
ADB pull <remote> <local> pulls files on device to local, such as copying a system application to D-disk, adb pull/system/app/a.apk d:\\
ADB install local Installation application
ADB uninstall <-k> package Uninstall app,-K for preserving app data and caching
ADB start-server start adb service, if it has been started, do not repeat boot
ADB kill-server stop ADB service
ADB remount mount devices with write access to devices
ADB reboot Restart device
ADB reboot-recovery Restart in brush mode
ADB root runs as root
2, Application of common directory
/data/data/package_name/Application Data directory, including cache, databases, LIB, shared_prefs, respectively, storage cache, database, LIB, sharedpreferences data
/data/system/dropbox Storage System FC, application FC, Application ANR, System boot log, log backup and so on. such as: [email protected] Indicates a point in time the ANR log, [email protected] for a point in time FC log.
You can use ADB pull to copy data locally,
ADB pull/data/data/cn.trinea.android.demo/databases/androiddemo d:\\ means copy database to D drive
ADB Pull/data/system/dropbox/d:\\systemnotes says that if a log is copied to the D drive
Related Blogs:
Android sqlite Command http://www.cnblogs.com/trinea/archive/2012/11/16/2773656.html
Devicemonitor Adb Connection Error: The remote host forced the shutdown of an existing connection workaround http://trinea.iteye.com/blog/1497145
Android AVD Manager does not recognize the real machine, adb driver resolves http://trinea.iteye.com/blog/1180522
The most common commands and applications of the ADB in Android