# Error: Read-only file system (/mnt/dietpi\_userdata/downloads

**URL:** https://dietpi.com/forum/t/error-read-only-file-system-mnt-dietpi-userdata-downloads/1206
**Category:** Troubleshooting
**Created:** [22 April 2017 14:16 UTC](https://dietpi.com/forum/t/error-read-only-file-system-mnt-dietpi-userdata-downloads/1206 "2017-04-22T14:16:27Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![ssr.karthikeya](https://dietpi.com/forum/letter_avatar_proxy/v4/letter/s/eada6e/32.png) [@ssr.karthikeya](https://dietpi.com/forum/u/ssr.karthikeya)
#### Post date: [22 April 2017 14:16 UTC](https://dietpi.com/forum/t/error-read-only-file-system-mnt-dietpi-userdata-downloads/1206/1 "2017-04-22T14:16:27Z")

</div>

Hi all,

The Dietpi Image is a fresh one v148 on a RPi 2 Model B (armv7l).

I used the Dietpi-Drive\_Manager tool to mount my 16GB kingston USB 3.0.

From time to time (~1 hour) the USB drive becomes a Read-Only file system. I cannot remount with **-rw** option since my dietpi\_userdata is located on this drive.

I have checked **/etc/fstab**

```nohighlight
#Internal Drives---------------------------------------------------
proc /proc proc defaults 0 0
/dev/mmcblk0p1 /boot auto defaults,noatime,discard 0 2
/dev/mmcblk0p2 / auto defaults,noatime,discard 0 1
tmpfs /tmp tmpfs defaults,noatime,nodev,nosuid,mode=1777 0 0
tmpfs /var/log tmpfs defaults,size=20m,noatime,nodev,nosuid,mode=1777 0 0
tmpfs /DietPi tmpfs defaults,size=10m,noatime,nodev,nosuid,mode=1777 0 0

#External Drives---------------------------------------------------
#NB: Please use dietpi-drive_manager to setup and control your external drives.

#Samba Client------------------------------------------------------
#/mnt/samba . Please use dietpi-config and the Networking Options: NAS menu to setup this mount

#FTP Client Mount--------------------------------------------------
#/mnt/ftp_client . Please use dietpi-config and the Networking Options: NAS menu to setup this mount

#NFS Client Mount--------------------------------------------------
#/mnt/nfs_client . Please use dietpi-config and the Networking Options: NAS menu to setup this mount
UUID=7b2aed01-97e1-4652-959a-6ab258fa9c86 /mnt/7b2aed01-97e1-4652-959a-6ab258fa9c86 auto defaults,noatime,nofail,x-systemd.automount,rw 0 0
# a swapfile is not a swap partition, no line here
# use dphys-swapfile swap[on|off] for that

```

I have specified the **rw** option in fstab. It doesn’st seem to clear the problem.

For some reason the Drive is mounted under “NFS Client Mount” instead of “External Drives” ❓ .

**blkid** shows:

```nohighlight
/dev/mmcblk0p1: SEC_TYPE="msdos" LABEL="boot" UUID="64EB-FD02" TYPE="vfat" PARTUUID="ee614650-01"
/dev/mmcblk0p2: LABEL="rootfs" UUID="6e11ba37-3d23-4d99-8ad6-b6a7a5fb372d" TYPE="ext4" PARTUUID="ee614650-02"
/dev/sda1: LABEL="downloads" UUID="7b2aed01-97e1-4652-959a-6ab258fa9c86" TYPE="ext4" PARTLABEL="Microsoft Basic Data" PARTUUID="34b8b6dc-6c26-443a-9265-fdc8db500e4f"
/dev/mmcblk0: PTUUID="ee614650" PTTYPE="dos"

```

**dmesg | grep “EXT4”** shows the following:

```nohighlight
[2.050076] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[7.564817] EXT4-fs (mmcblk0p2): re-mounted. Opts: discard
[10.995473] EXT4-fs (sda1): recovery complete
[11.000548] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)
[1095.276873] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 8388608 size 4194304 starting block 172544)
[1095.329410] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 8388608 size 4194304 starting block 172800)
[1095.381784] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 8388608 size 4194304 starting block 173056)
[1095.433674] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 8388608 size 4194304 starting block 173312)
[1095.486001] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 83886080 size 4194304 starting block 190976)
[1095.538376] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 83886080 size 4194304 starting block 191232)
[1095.590818] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 83886080 size 4194304 starting block 191488)
[1095.644227] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 83886080 size 4194304 starting block 191744)
[1095.697113] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 98566144 size 6291456 starting block 194560)
[1095.749296] EXT4-fs warning (device sda1): ext4_end_bio:329: I/O error -121 writing to inode 130573 (offset 98566144 size 6291456 starting block 194816)
[1102.068684] EXT4-fs error (device sda1): ext4_journal_check_start:56: Detected aborted journal
[1102.068703] EXT4-fs (sda1): Remounting filesystem read-only
[1102.068716] EXT4-fs (sda1): previous I/O error to superblock detected
[1102.071533] EXT4-fs (sda1): ext4_writepages: jbd2_start: 6144 pages, ino 130573; err -30

```

This effects my downloads in Transmission.

The USB drive is fairly new and has been used for a month or so , 24/7.

I found out that rebooting the Pi solves the problem. Also, a little research on **Fstab** showed that adding **errors=remount-rw** as a mount option may solve the problem but it didn’t.

---

<div class="post-metadata">

### Author: ![Fourdee](https://dietpi.com/forum/user_avatar/dietpi.com/fourdee/32/11_2.png) [@Fourdee](https://dietpi.com/forum/u/Fourdee)
#### Post date: [22 April 2017 14:26 UTC](https://dietpi.com/forum/t/error-read-only-file-system-mnt-dietpi-userdata-downloads/1206/2 "2017-04-22T14:26:18Z")

</div>

> From time to time (~1 hour) the USB drive becomes a Read-Only file system.  
> ext4\_end\_bio:329: I/O error -121 writing to inode 130573 (offset 8388608 size 4194304 starting block

I/O indicates drive is failing, or, insufficient power (ensure official PSU is used).

> For some reason the Drive is mounted under “NFS Client Mount” instead of “External Drives” \> ❓ \> .

When attaching drives in dietpi-drive\_manager, new entries are added to the end of file. Location in file has no bearing of its effect.

You could try formatting the drive again, see if that resolves it.

---

<div class="post-metadata">

### Author: ![ssr.karthikeya](https://dietpi.com/forum/letter_avatar_proxy/v4/letter/s/eada6e/32.png) [@ssr.karthikeya](https://dietpi.com/forum/u/ssr.karthikeya)
#### Post date: [22 April 2017 21:19 UTC](https://dietpi.com/forum/t/error-read-only-file-system-mnt-dietpi-userdata-downloads/1206/3 "2017-04-22T21:19:17Z")

</div>

> I/O indicates drive is failing, or, insufficient power (ensure official PSU is used).

I have been using the official Cannakit micro usb type 2.5A adapter, it must be the USB drive that’s failing.

> You could try formatting the drive again, see if that resolves it.

After a couple of stress tests on the drive (which resulted in no errors or bad blocks), formatting it to NTFS and changing the mount options with **umask** i.e

```plaintext
/dev/sda2 /win ntfs-3g rw,dev,exec,auto,async,users,umask=022,uid=1000,gid=1000,locale=en_GB.utf8, errors=remount-rw 0 0

```

The drive is running fine now. Although giving full permissions to a drive is a bad idea, for the time being, its fine by me. I will probably change them after a day or two with no errors in **dmesg**.
