Read-only file system Linux Origin: Platform & cloud OSI layer 7 · Application Last updated 15 Oct 2026

Read-only file system (EROFS) — cannot write to disk

The filesystem is mounted read-only — often because the kernel remounted it after detecting disk errors.

Exact message you may see Read-only file systemcannot create directory: Read-only file systemEROFS: read-only file system
Seen on: Linux

Meaning

ext4 and others are mounted with errors=remount-ro: on I/O errors or corruption the kernel flips the disk to read-only to protect data. It can also be intentional (container readOnlyRootFilesystem, snap/squashfs, a read-only bind mount, or macOS system volume).

Common causes

  • Disk errors or filesystem corruption (kernel remounted ro)
  • Failing disk or cloud volume detached
  • Mounted ro on purpose (fstab, container, live USB)
  • Writing into a read-only path (snap, /usr on immutable distros)

⚡ Quick fix

  1. Check the kernel log: dmesg | grep -i 'remount\|I/O error'
  2. Back up data, then fsck the volume and remount rw
  3. If intentional, write to a writable path (volume, /tmp)

Detailed fix by platform

Linux

  1. bash
    dmesg -T | grep -iE 'remount|I/O error|EXT4-fs error' | tail
    mount | grep ' ro,'
    sudo mount -o remount,rw /

How to diagnose

  1. Kernel log — Errors before the remount?
  2. Disk health — smartctl -a /dev/sda
  3. Intentional — fstab/container settings

🔧 Still not fixed?

Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:

Where this error sits

Origin: Platform & cloud. Errors that are often confused with or caused by this one (click to open):

0x80070020 — 0x80070020: The process cannot access the file because it is being used by another process (Windows)0x800700200x80070570 — Error 0x80070570: The file or directory is corrupted and unreadable (Windows)0x80070570Access to the path is denied — System.UnauthorizedAccessException: Access to the path 'x' is denied (.NET)Access to the path is…AccessDeniedException — java.nio.file.AccessDeniedException: /path (Java)AccessDeniedExceptionArgument list too long — bash: /bin/rm: Argument list too long (Linux)Argument list too longAuthentication token manipulation error — passwd: Authentication token manipulation error (Linux)Authentication token …EACCES — Linux: Permission denied (Linux)EACCESNo space left on device (inodes) — No space left on device, but df shows free space (inodes exhausted) (Linux)No space left on devi…Read-only…

Explore the map of this error Full error map →

🧠 Still stuck? Analyze your error

Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.

💬 What worked for others

No tips yet — did something else fix this for you?

Share what worked for you

Tips are checked by an editor before they appear. Links are removed.