您的位置:首页 > 移动开发 > Android开发

adb push 失败提示 ‘Read-only file system’

2016-01-04 15:56 579 查看

adb push 失败提示 ‘Read-only file system’

$ adb push ./xxx /xxx/
failed to copy './xxx' to '/xxx/xxx': Read-only file system


解决方法:

$ adb root
restarting adbd as root
$ adb remount
remount succeeded
$ adb push ./libbacktrace.so /system/lib/
2783 KB/s (58588 bytes in 0.020s)


已经按照上面的步骤做了,还是提示 ‘Read-only file system’怎么办

$ adb shell
# mount
/dev/block/by-name/android_system /system ext4 ro,seclabel,relati                             me,data=ordered 0 0


可以看到/system还是只读属性‘ro’,接下来我们把它remount成rw

#mount -o remount -o rw /system
#mount
/dev/block/by-name/android_system /system ext4 rw,seclabel,relati                             me,data=ordered 0 0


tips:

先 adb root 再adb remount 否则会出现下面的情况

$ adb remount
remount of system failed: Permission denied
remount failed


可能需要adb reboot 注意看命令行中的提示
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  android adb