# HelpÃ¯Â¼ÂšROOT MOUNT ERRORÃ¯Â¼Â



## hrbeu06ws (Dec 6, 2009)

*Helpï¼šROOT MOUNT ERRORï¼*

I'm a newcomer and after installing FreeBSD 8.0 Release, I reboot my computer and got an ERROR! System prompt:
..........

```
Root mount waiting for:usbus4
Trying to mount root form ufs:/dev/ad0s3a

ROOT MOUNT ERROR:
If you have invalid mount options, reboot, and first try the following from the loader prompt:

set vfs.root.mountfrom.options=rw
and the remove invalid mount options from /etc/fstab.

Loader variables:
vfs.root.mountfrom=ufs:/dev/da0s3a
vfs.root.mountform.options=rw

[manual boot prompt]
mountroot>
```
......... 
So I reboot system and try to change the loader variables like that, but no help! Somebody said to set hw.usb.ehci.no_hs=1, it also failed!
Who can help me to solve the problem! Thanks!


----------



## aragon (Dec 6, 2009)

Can you post the boot up messages?


----------



## hrbeu06ws (Dec 6, 2009)

I can't boot system and log in to the system. I try the safe mode, single user mode and disabled with ACPI, but it failed and got the same message like that "ROOT MOUNT ERROR". So I write down what I see on the screen and ask for help!


----------



## SirDice (Dec 6, 2009)

What does it show if you enter *?* (question mark)?


----------



## hrbeu06ws (Dec 7, 2009)

Add some boot up messages:

```
usbus0: 12Mbps Full Speed USB v1.0
usbus1: 12Mbps Full Speed USB v1.0
usbus2: 12Mbps Full Speed USB v1.0
usbus3: 12Mbps Full Speed USB v1.0
usbus4: 480Mbps High Speed USB v2.0
......
uhub0: 2 ports with 2 removable, self powered
uhub1: 2 ports with 2 removable, self powered
uhub2: 2 ports with 2 removable, self powered
uhub3: 2 ports with 2 removable, self powered

Root mount waiting for:usbus4
Root mount waiting for:usbus4
uhub4: 8 ports with 8 removable ,self powered
Root mount waiting for:usbus4
Trying to mount root form ufs:/dev/ad0s3a
......

Manual root filesystem specificaton:
<fstype>:<device> Mount <device> using filesystem <fstype>
eg. ufs:/dev/da0s1a
eg. cd9660:/dev/acd0
This is equivalent to: mount -t cd9660 /dev/acd0

?  List valid disk boot devices
<empty line> Abort manual input

[manual boot prompt]
mountroot>
......
```

After input question mark, it display that:

```
List of GEOM managed disk devices:
msdosfs/PROGRAM  ext2fs//  ext2fs//boot  ufsid/4b17922cec9adef8
ufsid/4b17922c8625a0ca  ufsid/4b17922dab2b1061  ufsid/4b17922c6039f71a
acd0  ad0s9  ad0s8  ad0s7  ad0s6  ad0s5  ad0s2f  ad0s2e  ad0s2d
ad0s2b  ad0s2a  ntfs/WINXP  ad0s3  ad0s2  ad0s1  ad0
```
My partition information in grub is that:

```
(hd0,0)  Filesystem type is ntfs  Windows XP
(hd0,1,a)  Filesystem type is ufs2  /
(hd0,1,b)  Filesystem type is unknown  swap
(hd0,1,d)  Filesystem type is ufs2  /var
(hd0,1,e)  Filesystem type is ufs2  /tmp
(hd0,1,f)  Filesystem type is ufs2  /usr
(hd0,4)  Filesystem type is ext2fs /boot
(hd0,5)  Filesystem type is ext2fs /
(hd0,6)  Filesystem type is Linux Swap
(hd0,7)  Filesystem type is fat
(hd0,8)  Filesystem type is ntfs
```


----------



## LateNiteTV (Dec 7, 2009)

it looks like your root partition is on a usb disk. did you install to a usb device?


----------



## hrbeu06ws (Dec 7, 2009)

No, I didn't insert any usb device when boot system!


----------



## jalla (Dec 7, 2009)

Your ufs2 partitions live in the first slice of ad0.

So try this

```
mountroot> ufs:ad0s1a
```

You probably have the other partitions wrong as well in /etc/fstab.
If thats the the case you should boot to singleuser and fix fstab.


```
mount -u /dev/ad0s1a
mount /dev/ad0s1X /var   # don't remember which is which
mount /dev/ad0s1Y /usr
vi /etc/fstab
```


----------



## hrbeu06ws (Dec 7, 2009)

First I try it like that:

```
mountroot> ufs:ad0s1a
```
or maybe

```
mountroot> ufs:/dev/ad0s1a
```
but get the same error:

```
Trying to mount root form ufs:/dev/ad0s1a

ROOT MOUNT ERROR:
If you have invalid mount options, reboot, and first try the following from the loader prompt:
......
```
after reboot system, I set the loader variables:

```
vfs.root.mountfrom=ufs:/dev/da0s1a
vfs.root.mountfrom.options=rw
```
also no help for me, same error.I can't boot single user mode.

I try to mount freebsd slice as readonly under linux and get my fstab:

```
# Device                Mountpoint      FStype  Options         Dump    Pass#
/dev/ad0s3b             none            swap    sw              0       0
/dev/ad0s3a             /               ufs     rw              1       1
/dev/ad0s3e             /tmp            ufs     rw              2       2
/dev/ad0s3f             /usr            ufs     rw              2       2
/dev/ad0s3d             /var            ufs     rw              2       2
/dev/acd0               /cdrom          cd9660  ro,noauto       0       0
```


----------



## SirDice (Dec 7, 2009)

Please answer my question in post #4


----------



## jalla (Dec 7, 2009)

jalla said:
			
		

> Your ufs2 partitions live in the first slice of ad0.



Sorry, I thought you were using grub2. The output from *grub* indicates that the magic words in your case are ad0s2X


----------



## hrbeu06ws (Dec 8, 2009)

SirDice said:
			
		

> Please answer my question in post #4



Please view post #5

```
After input question mark, it display that:
......
```


----------



## hrbeu06ws (Dec 8, 2009)

jalla said:
			
		

> Sorry, I thought you were using GRUB2. The output from `grub` indicates that the magic words in your case are ad0s2X



OK! The problem was solved. I used grub 0.97 to load my FreeBSD, but not grub2. I tried to mount /dev/ad0s2a and got some messages like that:

```
Trying to mount root form ufs:/dev/ad0s2a
Set hostuuid:...
Set hostid:...
Entropy harvesting: interrupts ethernet point_to _point kickstart
swapon: /dev/ad0s3b: No such file or directory
Start file system checks:
......
can't stat /dev/ad0s3e: No such file or directory
can't stat /dev/ad0s3f: No such file or directory
can't stat /dev/ad0s3d: No such file or directory
......
Unknow error; help! ERROR:ABORTING ROOT
/bin/sh on /etc/rc terminated abnormally, going to single user mode
......
```
When log in to the system, I mount the slice manually and fix fstab, now it works very well. Thank you for your help!

Maybe  FreeBSD could not recognize the slice correctly and got some error with fstab, but I want to ask why could that happen! I never have seen it before.


----------



## BlaisCk (Sep 28, 2013)

i'm newcomer on FreeBSD and i got same problem like this.

i read this post and still got stuck bcause can't understand the solution x(.

so can anyone post step by step to troubleshoot this problem?

I am a newcomer to FreeBSD and I have the same problem. I read this post and I am still stuck because I cannot understand the solution. Can anyone post a step-to-step guide to troubleshoot this problem?


----------



## Beastie (Sep 29, 2013)

I use FreeBSD 8.4 livefs to boot-up my server and using Fixit mode to be able to edit the file /etc/fstab, but it seems like the file is okay, *I* don't know where are wrong


```
# Device                Mountpoint      FStype  Options         Dump    Pass#
/dev/ad0s3b             none            swap    sw              0       0
/dev/ad0s3a             /               ufs     rw              1       1
/dev/ad0s3d             /var            ufs     rw              2       2
/dev/ad0s3e             /usr            ufs     rw              2       2
/dev/ad0s3f             /home           ufs     rw              2       2
/dev/ad0s3d             /data           ufs     rw              2       2
/dev/acd0               /cdrom          cd9660  ro,noauto       0       0
```

There are 2 entries for device /dev/ad0s3d.


----------



## BlaisCk (Sep 30, 2013)

Beastie said:
			
		

> There are 2 entries for device /dev/ad0s3d.



*I* thought that's the problem, but after *I* commented that /data and rebooted my server, the problem is still in there.


----------



## kpa (Sep 30, 2013)

You're saying that you have the same problem as the original thread starter but how did this problem start for you? After an OS update/upgrade or how?


----------



## BlaisCk (Sep 30, 2013)

*M*y job's friend just look at my server for routine maintenance, then he got the server has / partition is full (-750 MB), but my friend dont doesn't care about that, *I* don't know exactly what happens until he reboots the server and then got that message.


----------



## zehfi (Oct 1, 2013)

To boot into single user mode, just do it at the boot screen. When done you will be asked for a custom shell or enter key for /bin/sh. Just hit enter.
 Then run `fsck -t ufs -yf `your root partition``. If fsck(8) fails then I cannot help you.
 If it works the next step is to mount your drive manually with this command: `mount -t ufs /dev/`your root partition` /mnt`. Normally at this point it should work, if not, again I cannot help you.
 Check /etc/fstab for errors and edit it with your favorite text editor then reboot to see if it works.
If it is not working then give us the error message you get please.


----------



## BlaisCk (Oct 9, 2013)

I can not use single user mode, because the result is the same as descripted at first post.
I'm able to mount my root partition and doing fsck via livefs, and edit my /etc/fstab, but if I reboot my machine, ht result still same.


----------



## zehfi (Oct 10, 2013)

If you have 2 drives that are the same size or the second is higher than the first one, backup the second one (the one that is not the boot device).
Boot on CDROM, then execute this command: `dd if='boot drive' of='2nd drive' bs='100m or the higher you can put'`.
After that you can boot on you're 2nd drive and see if it's works. If it is then you first drive won't be bootable anymore but will still work as a storage device.


----------



## wblock@ (Oct 10, 2013)

That seems... confused.  Blowing away the first 100M of a disk is not necessary, and will lose data.

The first thing to do after that root mount error is to try again.
The second is to post here, describing the system.  The error can be caused by several things, and knowing the type of system and disk controller can help.


----------



## zehfi (Oct 11, 2013)

I did not say that he should throw away 100MB! I said that he should try to copy one disk to another to see if it is the drive that cause problems.


----------

