# Root filesystem could not be mounted read/write

## emrys404

Hello,

I just recently upgraded my kernel from 2.6.12-r6 to 2.6.19-r5 and in the process i also upgraded udev and removed coldplug. I followed the instructions in gentoo handbook kernel upgrade guide but now when i boot into the new kernel i get "Root filesystem could not be mounted read/write" when booting up.

Of course since i removed coldplug i hosed my other kernel and cant get back into it nor get internet access so i'm kinda up a creek.

Do you guys have any idea how to fix this error?

Thanks in advance,

-Emrys

----------

## bunder

 *emrys404 wrote:*   

> Hello,
> 
> I just recently upgraded my kernel from 2.6.12-r6 to 2.6.19-r5 and in the process i also upgraded udev and removed coldplug. I followed the instructions in gentoo handbook kernel upgrade guide but now when i boot into the new kernel i get the following error: "Root filesystem could not be mounted read/write".
> 
> Of course since i removed coldplug i hosed my other kernel and cant get back into it nor get internet access so i'm kinda up a creek.
> ...

 

can you give us a little more info?  "root filesystem could not be mounted read/write" is a rather generic error... we need to see a few lines before that as well...  that'll tell us why it couldn't be mounted.

cheers

----------

## emrys404

Thanks for the quick reply. 

There is not much more there:

```

Activing mdev

Determining root device...

Mounting root...

INIT: version 2.86 booting

Gentoo Linux; http://www.gentoo.org/

copyright 199-2007 gentoo Foundation; Distrubted under the GPLv2

Press I to enter interactive boot mode

Mounting proc at /proc [ok]

Mounting sysfs at /sys [ok]

Mounting /dev for udev [ok]

Seeding /dev with needed nodes [ok]

Setting up proper hotpug agent

     Using netlink for hotplug events [ok]

Starting udevd [ok]

Populating /dev with existing devices through uevents [ok]

Letting udev process events

     udev loading module via_agp

     udev loading module nvidia

     udev loading module i2c-viapro

     udev loading module tulip

     udev loading module snd_emu10k1

     udev loading module pcspkr

Finalizing udev configuration [ok]

Mounting devpts at /dev/pts [ok]

Checking root filesystem [ok]

Reiserfs super block in block 16 on 0x1603 of format 3.6 with standard journal

Blocks (total/free): blah blah blah

Filesystem is clean

Filesystem seems mounted read-only. Skipping journal replay.

Checking internal tree..finished [ok]

Remounting root filesystem read/write

Root filesystem could not be mounted read/write [!!]

Give root password for maintenance

or type Control-D to continue):

```

All errors after this are related to not being able to write to root.

Let me know if i can provide any more info,

thanks in advance

-emrys

----------

## bunder

positive that there is nothing in between...

```
Checking internal tree..finished [ok]

Remounting root filesystem read/write
```

and...

```
Root filesystem could not be mounted read/write [!!]

Give root password for maintenance

or type Control-D to continue): 
```

 :Question: 

if not, try booting with a livecd and fsck.

cheers

----------

## emrys404

Yeah, nothing between those two lines.

I dont think its a problem with the disk because when i boot into my old kernel, even though no modules load and a bunch of errors occur, it will load it read/write.

But i'll give the livecd a try as i'm completely flummoxed  :Smile:  no errors to speak of and search for just the main one and not much on google or these forums.

Thanks,

emrys

----------

## bunder

maybe you missed something in your IDE setup then.

cheers

----------

## wynn

The bits about mounting root readonly and read/write are in /etc/init.d/checkroot.

The line just before "INIT...", "Mounting root..." should mount the root filesystem readonly so it can be checked â the default is for the kernel to mount it readonly but this can be overridden by the "rw" parameter on the kernel command line.

Presumably you haven't got this set in your GRUB/LILO boot configuration.

check root will try a "touch" command to see if root is mounted read/write and, if it is, will attempt to remount it readonly: it will issue the message "Remounting root filesystem read-only" if it has to do this: no such message, root is mounted readonly.

Then it checks the root line in /etc/fstab to see if the passno is 0 â if it isn't, it will run fsck on root: according to your messages "Checking root filesystem [ok]" this worked. The following reiserfs messages all come from this fsck.

It then checks to see if root is mounted readonly (again) and, if it is, tries to mount it read/write â it is at this point, executing

```
mount -n -o remount,rw / &> /dev/null
```

and getting a mount return code showing it hasn't succeeded, that the error message appears.

I would suggest giving the root password, which will put you into a shell, and running

```
cat /proc/mounts
```

and

```
mount -n -v /
```

 and posting the output: "-n" prevents mount writing into /etc/mtab as root is still readonly, and "-v" is verbose mode which will, hopefully, give us a clue   :Smile: 

----------

## emrys404

Thanks for the reply and all the great info.

Okay:

cat /proc/mounts

```

rootfs / rootfs rw 0 0

/dev/hdc3 / reiserfs ro 0 0

proc /proc proc rw,nosuid,nodev,noexec 0 0 

sysfs /sys sysfs rw,nosuid,nodev,noexec 0 0

udev /dev tmpfs rw,nosuid 0 0

devpts /dev/pts devpts rw,nosuid,noexec 0 0 

```

mount -n -v /

```

mount: /dev/hdc3 already mounted or / busy

```

and when i try to umount /dev/hdc3 it says its not mounted.

Hope that tells you something!

Thanks,

Emrys

----------

## emrys404

Okay fellas i think i figured it out. 

I had nolargeio=1 set in my /etc/fstab for that partition for playing neverwinter nights. I removed it and everything mounted just fine. Also nwn doesn't seem to need it anymore as it plays just fine as well.

Hope that helps someone. Thanks for all your help guys,

-Emrys

----------

## pumazi

I had the same error message after an installation.  In /etc/fstab I had the root filesystems mount options as 'defaults,noatime' ... simply removing 'defaults' solved the problem.  Don't know why, but it worked.  I figured I would post because this lead me to the general area that solved the problem.  thanks.

----------

## edomaur

I have the same problem. I will try to remove the "defaults" in fstab, but I don't think that it has something to do with this. In my error message, there is a comment about a "-u" not being a valid option for "mount". (I can not copy the exact message for the moment)

My computer is an Athlon X2 4400+ on an Asus nVidia board. The computer is a fresh install. I have emerged a full system update (emerge -e system) after having updated (with some pain, the SATA setting is not in the same submenu, so genkernel is not copying it in the new config...) the kernel from the 2006.1 default to the current 2.6.20 gentoo-sources, and then shblam ! it doesn't pass the init phase anymore. 

What is really sad with this is that actually I have _no_ time for this kind of crap, really. I have fighted Gentoo since friday and basically lost 4 days. This afternoon I will reinstall that new computer with a Kubuntu. 

It hurts. 

Perhaps I will come back with 2007.0... Perhaps...

----------

