linux中重新挂载改写权限方法

1 开启终端;

2 adb shell连接终端,如果不是root用户,要手动切换到root用户,adb root;

3 输入mount命令,显示已挂载列表:

rootfs / rootfs ro,relatime 0 0
tmpfs /dev tmpfs rw,nosuid,relatime,mode=755 0 0
devpts /dev/pts devpts rw,relatime,mode=600 0 0
proc /proc proc rw,relatime 0 0
sysfs /sys sysfs rw,relatime 0 0
none /acct cgroup rw,relatime,cpuacct 0 0
tmpfs /mnt/asec tmpfs rw,relatime,mode=755,gid=1000 0 0
tmpfs /mnt/obb tmpfs rw,relatime,mode=755,gid=1000 0 0
none /dev/cpuctl cgroup rw,relatime,cpu 0 0
/dev/block/mmcblk0p12 /system ext4 ro,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p20 /data ext4 rw,nosuid,nodev,relatime,barrier=1,data=ordered,noauto_da_alloc 0 0
/dev/block/mmcblk0p14 /persist ext4 rw,nosuid,nodev,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p15 /cache ext4 rw,nosuid,nodev,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p13 /system/flex ext4 ro,nosuid,nodev,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p16 /tombstones ext4 rw,nosuid,nodev,relatime,barrier=1,data=ordered 0 0
/dev/block/mmcblk0p1 /firmware vfat ro,relatime,fmask=0000,dmask=0000,allow_utime=0022,codepage=cp437,iocharset=iso8859-1,shortname=lower,errors=remount-ro 0 0
/dev/fuse /emmc fuse rw,nosuid,nodev,relatime,user_id=1023,group_id=1023,default_permissions,allow_other 0 0
#
4 找到要改写权限的挂载目录,如/system对应/dev/block/mmcblk0p12,按如下指令挂载

mount -o rw,remount /system /dev/block/mmcblk0p12或者

mount -o rw,remount /dev/block/mmcblk0p12 /system

5,再次用mount查看修改权限是否成功


你可能感兴趣的:(linux,shell,user,ext,终端,permissions)