Adb shell進入目標設備的Linux Shell環境
$ ps 列出所有進程
$ ps|grep xxx 刷選xxx相關進程
殺死進程
kill -s 9 PID
Kill -9 PID @link
Kill進程
重新掛載:
mount -o remount,rw rootfs /system/
復制/刪除:
復制 cp /system/xbin/sudo /system/xbin/su 格式:cp 源文件 目標文件
刪除 rm -f /system/xbin/su 或 rm /system/xbin/su
S1、刪除文件夾以及文件夾中的所有文件命令:
rm -rf 目錄名字
其中:
-r:向下遞歸刪除
-f:直接強行刪除,且沒有任何提示
S2、刪除文件命令
rm -f 文件名
將會強行刪除文件,且無提示@link
移動 mv /sbin/su /sbin/aa @link
mv /system/xbin/daemonsu /system/xbin/usonmead
cp /system/xbin/usonmead /system/xbin/daemonsu
Am/pm:
am kill com.kingroot.RushRoot @link link2
pm uninstall com.kingroot.RushRoot 卸載
pm install –f filePath 安裝
pm uninstall eu.chainfire.supersu @link
pm block com.xxx.xxx(包名) 凍結 ← 適用於 Android 4.4.x
pm hide com.xxx.xxx(包名) 隱藏 ← 適用於 Android 5.0 以上版本
權限/屬性:
表達式 chmod 權限 目標文件
例子:
chmod 0777 /system/bin/.ext
chmod 06755 /system/bin/.ext/.su
chmod 06755 /system/xbin/su
chmod 0755 /system/xbin/daemonsu
chmod 0755 /system/etc/install-recovery.sh
chmod 0755 /system/etc/init.d/99SuperSUDaemon
chmod 0644 /system/etc/.installed_su_daemon
chmod 0644 /system/app/Superuser.apk
打印:
echo "\"It is a test\"" @link
參考:
adb shell中的am pm命令 AM/PM命令