I have a laptop running Ubuntu Server 12.04 and suddenly, yesterday, I don't know what happened, but all the permissions changed of my home directory, so when ever I try to create a file, it says something like:
mkdir: cannot create directory 'Samba': Read-only file system

Note: This is in my home folder, not in the root folder or many of it's sub folders.

  • 1
    Paste the outputs of mount | grep home | column -t and ls -ld /home/<user>.
    – user26112
    Aug 12, 2013 at 13:57

2 Answers 2


From the error it would seem that the disk partition your home directory resides is mounted read-only. You can verify that by issuing the following command in a terminal prompt:

mount | grep home

That should output something like:

/dev/xxxxx on /home type ext3 (ro)

Note the ro in parenthesis for read-only. If that command gives no output, probably the home directory is on the root partition, and if you don't know which that is, it can similarly be found e.g. by

mount |grep "/ type"

which might again output something like

/dev/xxxxx on / type ext3 (ro,errors=remount-ro)

To remount the partition read-write (substitute xxxxx with the correct partition):

mount -o remount,rw /dev/xxxxx

If a filesystem suddenly becomes read-only and you have no idea why, what probably happened is that the operating system detected a disk input/output error or a bug in a storage driver. When the kernel detects such an error, this indicates that some data is getting corrupted. It forcibly remounts the filesystem read-only in order to limit the potential to further corruption.

Check your system logs — usually /var/log/kern.log or /var/log/messages or /var/log/syslog. You'll find a line containing kernel: Remounting filesystem read-only. The lines before that show what happened.

If the disk seems to be the culprit, you'll need to change it. Note that sometimes what looks like disk errors are instead caused by a damaged or badly inserted cable, or by faulty RAM.

While you can remount the filesystem as read-write, this is not recommended: there's a strong risk that you'll make the problem worse. Leave it read-only until you've identified and repaired the root cause (which usually requires a reboot anyway).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .