PDA

View Full Version : [ubuntu] Read Only Filesystem after update



prahs rozar
November 5th, 2008, 09:24 AM
Starting a few weeks ago, whenever I attempt to update any software through the update manager it will tell me when it starts installing that I have a read only file system. This affects all other programs, and after I restart I have to run fsck. I always have to go through many file system problems and fix them whenever this happens, but it always seems to work again after I fix them. This seems to have happened every time I have tried to update software since then, but it is probably not a problem with Synaptic or APT because I have been able to install and remove programs without trouble. The first time this happened I thought it was caused by Java since I just installed it and it was getting an upgrade, but I have completely removed it and the same issue reoccurs.

persistentstubborn
November 5th, 2008, 09:42 AM
..., whenever I attempt to update any software through the update manager it will tell me when it starts installing that I have a read only file system. This affects all other programs, and after I restart I have to run fsck. I always have to go through many file system problems and fix them whenever this happens, but it always seems to work again after I fix them.

I'm no expert, by any means, but it seems it's just what's reported - there is an encrypted filesystem on your HDD.

Could you:


your@pc:~$ sudo cat /etc/fstab

and paste the output here? There could be some misconfiguration there.

prahs rozar
November 5th, 2008, 09:49 AM
# /etc/fstab: static file system information.
#
# -- This file has been automaticly generated by ntfs-config --
#
# <file system> <mount point> <type> <options> <dump> <pass>

proc /proc proc defaults 0 0
# Entry for /dev/hda2 :
UUID=cddc4fb1-9c1c-464f-9940-fdca75d50a38 / ext3 relatime,errors=remount-ro 0 1
# Entry for /dev/hda3 :
UUID=125ef2ed-7c0d-436b-acda-43ea9285321d none swap sw 0 0
/dev/hdc /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0
/dev/hda1 /media/hda1 ntfs-3g defaults,locale=en_US.UTF-8 0 0
#/dev/sda1 "/media/usb ext hd I" ntfs -3g force 0 0

persistentstubborn
November 5th, 2008, 10:48 AM
# /etc/fstab: static file system information.
#
# -- This file has been automaticly generated by ntfs-config --
#
# <file system> <mount point> <type> <options> <dump> <pass>

proc /proc proc defaults 0 0
# Entry for /dev/hda2 :
UUID=cddc4fb1-9c1c-464f-9940-fdca75d50a38 / ext3 relatime,errors=remount-ro 0 1
# Entry for /dev/hda3 :
UUID=125ef2ed-7c0d-436b-acda-43ea9285321d none swap sw 0 0
/dev/hdc /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0
/dev/hda1 /media/hda1 ntfs-3g defaults,locale=en_US.UTF-8 0 0
#/dev/sda1 "/media/usb ext hd I" ntfs -3g force 0 0

It seems your "/" partition is being mounted with inappropriate option "relatime". Man mount says it's an option to "update inode access times relative to modify or change time".

To determine what option exactly work for your "/" when fsck has finished his job, execute:


your@pc~$:cat /etc/mtab

end determine which option is listed for your /dev/hda2.

To save a backup copy of your still somewhat working /etc/fstab execute


your@pc~$:sudo cat /etc/fstab > /etc/fstabold

so you would be able to replace it in case something goes wrong.

Than edit your /etc/fstab and write the appropriate option. My ubuntu /etc/fstab for "/" reads


UUID=cddc4fb1-9c1c-464f-9940-fdca75d50a38 / ext3 defaults,errors=remount-ro 0 1

But it's still a safe bet to place what your /etc/mtab says.

After you do it, reboot and wait to see what's happening.

Mind,your box might become non-bootable in case of wrong option written in /etc/fstab. In that case, you'll need to boot from another media (floppy, live session of install cd, etc.), to mount "/" and replace modified /etc/fstab modified per these instructions with /etc/fstabold. That would look like this:

(Write it down on paper in case you don't know it, so you could execute it without access to internet.)


#mkdir /media/disk
#mount -t ext3 /dev/hda2 /media/disk rw
#cd /media/disk
#pico /etc/fstabold
Ctrl-O
save the output as /etc/fstab (are you sure you want to save the file as /etc/fstab? file exists - Y
#shutdown -r now

And you'll be back again in your poorly working fstab.

It would be nice if you report the results here.

Edit: Most stupid typo ever. I hope you either wouldn't need it, or you figure out yourself that the intention was to replace non-bootable /etc/fstab with poorly woorking /etc/fstaboold.

prahs rozar
November 11th, 2008, 09:36 PM
I followed your advice, and everything seems to work, but I still can't get updates. I don't get anything about a read only filesystem, and I am able to close it, but I get this message:

E: dpkg was interrupted, you must manually run 'dpkg --configure -a' to correct the problem.
E: _cache->open() failed, please report.

When I try doing that I get this:

dpkg: error processing evince (--configure):
Package is in a very bad inconsistent state - you should
reinstall it before attempting configuration.
Errors were encountered while processing:
evince