Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 6 Jun 2013 16:18:24 +0200
From:      Polytropon <freebsd@edvax.de>
To:        Andrew Hamilton-Wright <ahamiltonwright@mta.ca>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Boot hangs in single-user mode
Message-ID:  <20130606161824.4c45f579.freebsd@edvax.de>
In-Reply-To: <D740464A-BDF9-4012-9629-D98383D0FB83@mta.ca>
References:  <D740464A-BDF9-4012-9629-D98383D0FB83@mta.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 6 Jun 2013 10:24:52 -0300, Andrew Hamilton-Wright wrote:
> 
> Strangely, it seems that I cannot boot single user, either
> using "boot -s" from the boot loader, or using the boot menu. 
> When I get to the point where the root filesystem is mounted,
> it hangs right after printing the message:
> Trying to mount root from ufs:/dev/ada0s1a

Have you tried hitting the RETURN key several times? I've
seen what you've described once (I think on a FreeBSD 5
system): The prompt

	Enter full pathname of shell or RETURN for /bin/sh: _

would not appear, but the system was still responding.
Hitting RETURN made that prompt visible and the SUM shell
prompt was properly displayed.

It's important to identify if the system is _really_ hanging,
or if the message "just isn't visible"...



> Interestingly, there seems to be a bit of a sequence issue,
> as I have also seen the mount message appear before the audio
> system comes up, so occasionally, the last item printed is:
> pcm0:  <USB audio> on uaudio0

This seems to indicate that the system is still responding,
i. e., the kernel is "up and running". Whenever "new" hardware
is detected, the kernel will issue a console message.

For example, on my home system the detection of the built-in
USB is sometimes a bit slow, so its messages appear "later on"
in the booting sequence, _after_ the initial kernel messages
(e. g., during firewall initialisation).



> I suspect that this may be a race condition of some kind, as
> yesterday I am sure I successfully booted to single-user while
> trying to solve a separate problem.

Try some more. :-)



> I am rebooting the machine at the moment as I wish to ensure
> that I know which physical disk is ada2, so want to boot the
> machine without it plugged in.

A suggestion: I tend to keep a tendency to use labels instead
of device names to identify disks. This is handy in case you're
running some kind of RAID configuration or use striping and
mirroring. Mark the disks with numbers and colors, as you prefer
(for example this nomenclature: color = stripe, number = mirror),
to reflect "being element of a stripe" and "being one of the
mirrors of N" properties both by the label (software) and the
physical disk (hardware). So you can _directly_ deduct from
a label (for example of a disk that is reported as failing)
like "red 2" that the disk is the 2nd mirror disk in the "red"
stripe, and _which_ physical disk is it? The one with a red "2"
on it. :-)





-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130606161824.4c45f579.freebsd>