Android mounts file system with write permission

The Android device I use does not hold sqlite3 on it, so I thought of push it on the device after pull with its AVD.

I had no problems extracting it from the AVD, although I cannot click it on the device, since I need to enable write permission. I tried to execute sqlite3: not found

I tried the following

 $ adb -d shell $ mount mount rootfs / rootfs ro,relatime 0 0 tmpfs /dev tmpfs rw,relatime,mode=111 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 tmpfs /mnt/usb tmpfs rw,relatime,mode=755,gid=1000 0 0 tmpfs /app-cache tmpfs rw,relatime,size=7168k 0 0 none /dev/cpuctl cgroup rw,relatime,cpu 0 0 /dev/block/mmcblk0p9 /system ext4 ro,relatime,barrier=1,data=ordered 0 0 /dev/block/mmcblk0p7 /cache ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered /dev/block/mmcblk0p1 /efs ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered 0 nil /sys/kernel/debug debugfs rw,relatime 0 0 /dev/block/mmcblk0p10 /data ext4 rw,nosuid,nodev,noatime,barrier=1,data=ordered, /dev/block/mmcblk0p4 /mnt/.lfs j4fs rw,relatime 0 0 /dev/block/vold/179:11 /mnt/sdcard vfat rw,dirsync,nosuid,nodev,noexec,noatime,n epage=cp437,iocharset=iso8859-1,shortname=mixed,utf8,errors=remount-ro,discard 0 

I followed this link and tried to mount the file system as follows, but I got a permission error.

 $ mount -o rw,remount -t yaffs2 /dev/block/mmcblk0p9 /system mount: Operation not permitted 

What key do I need to push sqlite3 to an Adroid device for debugging?

+3
source share
3 answers

The solution is simple. To reinstall the mounted system you need to have root privileges. Do su . You will enter root mode. Then run the command below. It will work, I have done it many times.

So here are the steps:

  adb shell su mount -o rw,remount /system 

Edit: found a better solution

On the host machine (Linux or Windows PC), run the following commands.

 >> adb root >> adb remount 

remount will by default remount / system partition with rw if you have permissions.

Note 1: To execute su or adb root commands, your device must be rooted and have an executable file on it. If the su command is successful, the terminal request will change from $ to # .

Note 2: On the latest mobile phones, security has been tightened, and even after rooting the phone, adb remount will not work. As far as I know, there is still no solution.

+19
source

As mk points out, many newer phones have adb root and adb remount disabled. My LGL34C is locked, and adb is pretty much only useful for loading into protected areas of the file system.

But there is a way around him (ALWAYS there)! Of course, you still need a built-in phone with su. Install the terminal terminal and / or sshd service on the phone. Rebooting and writing to / system work fine with the local OS.

0
source

The main reason you didn’t have rights ... no root on this script hince the $ su turns this into #, I believe ....

0
source

All Articles