[PLUG] Ubuntu 30-boot forced fsck

chris (fool) mccraw gently at gmail.com
Thu May 15 17:56:13 UTC 2008


On 5/15/08, Rogan Creswick <creswick at gmail.com> wrote:
> On 5/15/08, Denis Heidtmann <denish at dslnorthwest.net> wrote:
>  >  Partition /dev/hdb1 is mounted with write permissions, cannot check it
>  >
>  >  How to handle this? There was something I read about single-user mode, but it
>  >  was beyond my knowledge.  Is a live CD boot an option?  It seems to me that a
>  >  read-only test limits the type of problems that can be detected.
>
>
> You generally can't check a filesystem that can be written to because
>  something might change while the check is going on, and it could
>  incorrectly report errors.  There may very well be more dangerous
>  consequences too -- I'm not sure, but it seems reasonable that the FS
>  check is going to be doing things that normal programs shouldn't
>  interfere with.
>
>  Therefore, you've got to mount the partition as read only:
>
>  $ sudo mount -o remount,ro /dev/hdb1
>
>  should do it.
>
>  When the check is done:
>
>  $ sudo mount -o remount,rw /dev/hdb1
>
>  (running from memory, the last part may need to be a mount point, eg:
>  / not a device)

it works either way (device or mount point).  you may also find the
"-n" flag to mount useful--i use it by reflex now, since it was at
some point required to move an FS from R/O to R/W or back.

note:  mounting an actively in-use (ie being written to) volume
read-only may cause some havoc with stuff crashing as it can't write
needed files.  gnome definitely tanked once when i did that.  it's
been years since i used gnome though, so hopefully developers have
gotten smarter with failing gracefully...  and certainly you'll lose
some syslog info if you were to do that to the partition syslog would
write to.

so don't leave it r/o for longer than you need =)



More information about the PLUG mailing list