First Last Prev Next    No search results available      Search page      Enter new bug
Bug#: 187628
Alias:
Product:
Component:
Status: VERIFIED
Resolution: FIXED
Assigned To: Gentoo's Team for Core System packages <base-system@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Markus Rothe <corsair@gentoo.org>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
linux_rw.txt startup with "rw attached to kernel" text/plain Markus Rothe 2007-08-04 16:09 0000 2.91 KB Details
console.patch Only setfont if we have a console patch Roy Marples (RETIRED) 2007-08-04 18:30 0000 464 bytes Details | Diff
console.patch Only setfont if we have a conslole and ensure exit 0 patch Roy Marples (RETIRED) 2007-08-04 19:05 0000 904 bytes Details | Diff
console.patch Only setfont if we have a conslole and ensure exit 0 patch Roy Marples (RETIRED) 2007-08-04 19:34 0000 896 bytes Details | Diff
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 187628 depends on: Show dependency tree
Show dependency graph
Bug 187628 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2007-08-03 17:10 0000
I've two problems with baseyout-2*:

First problem is that sys-apps/baselayout-2.0.0_rc1 does not boot with
read-only root filesystem. I have to append "root=/dev/sda3 rw" to the kernel
options, else I'm getting this:

(this is powerpc64 and it *did* boot without rw appended the first time I
booted with baselayout-2*. I've seen this after first reboot. I've upgraded
from baselayout 1* straight to 2*)


Welcome to yaboot version 1.3.13
Enter "help" to get some basic usage information
boot: linux
Please wait, loading kernel...
   Elf64 kernel loaded...
Loading System.map ...
System.map loaded at 01a00000, size: 1024 Kbytes
OF stdout device is: /pci@fef00000/isa@b/serial@i3f8
command line: root=/dev/sda3 
memory layout at init:
  alloc_bottom : 000000000186f000
  alloc_top    : 0000000020000000
  alloc_top_hi : 0000000020000000
  rmo_top      : 0000000020000000
  ram_top      : 0000000020000000
Looking for displays
found display   : /pci@fee00000/display@b, opening ... done
[...]
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 10
lo: Disabled Privacy Extensions
tunl0: Disabled Privacy Extensions
IPv6 over IPv4 tunneling driver
sit0: Disabled Privacy Extensions
NET: Registered protocol family 17
kjournald starting.  Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 176k freed
INIT: version 2.86 booting
INIT: Entering runlevel: 3
 * failed to open `/lib64/rcscripts/init.d/softlevel': Read-only file system


This is (none) (Linux ppc64 2.6.21.6) 17:56:21

(none) login:



The second problem is, that /proc does not get mounted if I append
"root=/dev/sda3 rw". /proc is empty.

------- Comment #1 From Roy Marples (RETIRED) 2007-08-04 15:20:44 0000 -------
Could you check the dates of /etc/profile.env and
/lib/rcscripts/init.d/deptree?

Also, see if moving those files to /tmp and regenerating them helps
/sbin/env-update
/etc/init.d/urandom restart

If it does help, then please attach those files here so  I can see what is
causing rc to crash out.

------- Comment #2 From Markus Rothe 2007-08-04 15:45:35 0000 -------
This are the dates (before regenerating the two files):

power3 ~ # ls -lh /etc/profile.env 
-rw-r--r-- 1 root root 845 Aug  4 16:39 /etc/profile.env
power3 ~ # ls /lib64/rcscripts/init.d/deptree -lh
-rw-r--r-- 1 root root 5.9K Aug  3 17:29 /lib64/rcscripts/init.d/deptree
power3 ~ # date
Sat Aug  4 16:40:47 CEST 2007


I've regenerated the files now, but that didn't help. I'm getting the same
error.

------- Comment #3 From Roy Marples (RETIRED) 2007-08-04 15:59:00 0000 -------
Interesting that rc doesn't appear to be running at all.

Try this
RUNLEVEL="1" /sbin/rc sysinit

If that fails, could I get a strace of it please?
Or backtrace if it dumps core.

------- Comment #4 From Markus Rothe 2007-08-04 16:07:47 0000 -------
power3 ~ # RUNLEVEL="1" /sbin/rc sysinit
GCouldnt open /dev/console
power3 ~ # ls /dev/console -l
crw------- 1 root tty 5, 1 Aug  4 16:58 /dev/console
power3 ~ # chmod g+rw /dev/console 
power3 ~ # RUNLEVEL="1" /sbin/rc sysinit
GCouldnt open /dev/console
power3 ~ # chmod o+rw /dev/console 
power3 ~ # RUNLEVEL="1" /sbin/rc sysinit
GCouldnt open /dev/console

doh?

------- Comment #5 From Markus Rothe 2007-08-04 16:09:33 0000 -------
Created an attachment (id=126861) [edit]
startup with "rw attached to kernel"

if I start the kernel with "rw", then /proc does not get mounted. This is how I
start the system currently.

------- Comment #6 From Markus Rothe 2007-08-04 16:38:48 0000 -------
I just did the following:

1. removing baselayout 2.0.0_rc1 (including all cruft; i.e. files modified by
me, so portage didn't unmerge them)
2. install baselayout 1.12.9-r2
3. reboot was successful (proc get's mounted and I can start without "rw")
4. update to baselayout 2.0.0_rc1 again
5. etc-update (let everything overwrite)
6. reboot and I'm getting the error

I'm not sure, why it booted the first time after the first upgrade, but I'm
pretty sure it did.

------- Comment #7 From Roy Marples (RETIRED) 2007-08-04 16:48:23 0000 -------
Could you add set-x near the top of /lib/rcscripts/sh/init.sh and
/lib/rcscripts/sh/init-early.sh so we can see where they're going wrong as I
think the error is there somewhere.

------- Comment #8 From SpanKY 2007-08-04 17:14:29 0000 -------
we should add a gentoo=debug or something that gets parsed at the start of boot
so people dont need to add 'set -x' and such ...

------- Comment #9 From Markus Rothe 2007-08-04 18:00:28 0000 -------
Placing "set -x" here and there I found this: if I place it exactly here

--- /lib64/rcscripts/sh/init-early.sh.orig      2007-08-04 18:27:43.000000000
+0200
+++ /lib64/rcscripts/sh/init-early.sh   2007-08-04 18:51:29.000000000 +0200
@@ -11,5 +11,6 @@
                CONSOLE="${CONSOLE:-/dev/console}"
                [ -c "${CONSOLE}" ] && cons="-C ${CONSOLE}"
                setfont ${cons} "${RC_LIBDIR}"/console/"${font}"
+               set -x
        fi
 fi


then the machine starts fine:


[...]
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 176k freed
INIT: version 2.86 booting
GCouldnt open /dev/console

   Gentoo/Linux; http://www.gentoo.org/
   Copyright 1999-2007 Gentoo Foundation; Distributed under the GPLv2

Press I to enter interactive boot mode

 * Mounting proc at /proc ...
 [ ok ]
[following output as usual]



If I place it one line above the "setfont" line, then it fails. Dunno what this
means.

I should note, that all output comes from serial console. There is no
monitor/keyboard attached to the machine, but the kernel seems to open the open
firmware device. ("found display   : /pci@fee00000/display@b, opening ... done"
at the very first lines of the kernel)

------- Comment #10 From Roy Marples (RETIRED) 2007-08-04 18:30:24 0000 -------
Created an attachment (id=126868) [edit]
Only setfont if we have a console

This should fix things

------- Comment #11 From Markus Rothe 2007-08-04 18:58:57 0000 -------
no, it does not... same error.

------- Comment #12 From Roy Marples (RETIRED) 2007-08-04 19:05:51 0000 -------
Created an attachment (id=126870) [edit]
Only setfont if we have a conslole and ensure exit 0

OK, I see what's happening here.
This patch should deffo fix it.

------- Comment #13 From Markus Rothe 2007-08-04 19:21:30 0000 -------
yes! that fixed it! thanks a lot! even the "Couldnt open /dev/console" message
is gone now.

Only one tiny little thing is missing ;-)

[...]
Freeing unused kernel memory: 176k freed
INIT: version 2.86 booting
G
   Gentoo/Linux; http://www.gentoo.org/
   Copyright 1999-2007 Gentoo Foundation; Distributed under the GPLv2
[...]

You see it? There is a "G". Where does that one come from?

------- Comment #14 From Roy Marples (RETIRED) 2007-08-04 19:34:13 0000 -------
Created an attachment (id=126875) [edit]
Only setfont if we have a conslole and ensure exit 0

Last one broke the early font, try this instead

------- Comment #15 From Roy Marples (RETIRED) 2007-08-04 19:36:01 0000 -------
(In reply to comment #13)
> [...]
> Freeing unused kernel memory: 176k freed
> INIT: version 2.86 booting
> G
>    Gentoo/Linux; http://www.gentoo.org/
>    Copyright 1999-2007 Gentoo Foundation; Distributed under the GPLv2
> [...]
> 
> You see it? There is a "G". Where does that one come from?

It's an ASCII escape code to put the console into unicode mode.
If you don't want to see it, then remove consolefont from the boot runlevel.

------- Comment #16 From Markus Rothe 2007-08-04 20:00:25 0000 -------
that last patch works fine, too.

(In reply to comment #15)
> It's an ASCII escape code to put the console into unicode mode.
> If you don't want to see it, then remove consolefont from the boot runlevel.

thanks for clarification. Unfortunately "rc-update" does not work as expected:

power3 ~ # rc-update del consolefont default
 * rc-update: unknown applet
power3 ~ # rc-update -s
 * rc-update: unknown applet
power3 ~ # rc-update -h
 * rc-update: unknown applet


another bug?

------- Comment #17 From Roy Marples (RETIRED) 2007-08-04 20:33:42 0000 -------
rc-update is already fixed in rc2, I'll push out an -r1 with this patch

------- Comment #18 From Roy Marples (RETIRED) 2007-08-04 20:39:27 0000 -------
Fixed in rc2-r1 - thanks.

------- Comment #19 From Roy Marples (RETIRED) 2007-08-04 20:40:16 0000 -------
(In reply to comment #8)
> we should add a gentoo=debug or something that gets parsed at the start of boot
> so people dont need to add 'set -x' and such ...

It's a good idea, but that only works if /proc is already mounted so we can
read the cmdline. So it wouldn't have helped in this case.

------- Comment #20 From Markus Rothe 2007-08-05 07:07:38 0000 -------
yes, perfect. :-)

First Last Prev Next    No search results available      Search page      Enter new bug