Dont edit file system

I tried to create a file or edit a file, and it all said it was read only file system. Although I used sudo or chmod 777. But nothing could be done. How to solve this problem?Thank you everyone


First I must admit I don’t have BPi-R2/R64, but I want try to help you. Things to check:

  1. Did you flash an clean image?

  2. Do you have something modified?

  3. Can you look at /etc/fstab?

    cat /etc/fstab

  4. If there’s a line with something called ‘ro’, then we found the problem.

  5. Maybe you can try ‘sudo mount -o remount,rw /’, but there could be one more problem: You can’t use sudo you just said. If you can, then you can try to edit /etc/fstab and remove the line (exactly the following, not the whole line): ‘errors=remount-ro’ or something with ‘ro’

  6. Because interfaces.swp is essentially a swap file, then you can try ‘sudo swapoff -a’. This turns off the swap-file and then try to edit the file.

  7. Last question: Is the whole filesystem locked, because of read only? Or is it only that file? If I read your text, then I think the whole filesystem. Maybe you can send one more photo from another file/folder.

  8. One thing you can try too, is try to read the micro-SD from a Linux computer if you’re running your operating system from your SD. Maybe you can write from that PC. Then it’s probably /etc/fstab if you can read it.

I like to hear more from you soon.

Have a nice day!


Which image you are using?

Please post output of mount-command (without arguments)

this is here. version:BPI-M4/BPI-W2 Ubuntu Server 16.04 2019-08-23-ubuntu-16.04-lite-preview-bpi-r64-sd-emmc

thank you so much.i will check it

Your root filesystem is mounted ro. Can you post output of

cat /etc/fstab

I’ll take a look at the image you send. Maybe I can find a fault within the image.

in case 7 : I think all the files are the same.

this is here

Can you please post the output of

cat /etc/fstab


I will take a look at the output, maybe there’s some line with ro

thank you! I don’t see a line with ro

Can you run

sudo mount -o remount,rw /


And then post output of


That’s weird. Can you reflash the image? Then we have a clean start.

You can backup current image with dd

In the image I don’t see any line with ro

But I see /dev/mmcblk0p2

It’s better to use UUID in image (/etc/fstab), because /dev/mmcblk0 changes sometimes.

Maybe the problem is with the image?

It’s possible. Do you have errors with the SD card when you boot? Sometimes a power corruption can damage the SD and/or installation of the image. But I want to make sure it’s not the SD/installation. I will in the meantime take a look at the image. I’ll take a look if I can see that can cause any possible errors.

Maybe we can create a new image of this one and make it better work. Can you in the meantime reflash the image? Then we have a clean start… But take a backup before reflashing if the image is important to you…

I just reset it. but

I’ll try to change the UUID of image. I’ll send it to you when I’m ready. Do you want to test it out then?

It’s not mount ro anymore I see. Can you edit files?