Google luky.org euqset.org

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Kernel 2.6.10 Can't Open Initial Console on FC3


On Fri, 31 Dec 2004 00:31:38 -0600, "Joseph D. Wagner" <technojoecoolusa@xxxxxxxxxxx> wrote:

> The newly compiled kernel gets through everything OK including mounting
> the root file system as read-only EXT3.  However, it freezes on the very
> last line, which says:
> 
>      Warning: unable to open an initial console

> I feel like an idiot for posting this.  I'm probably missing something obvious.

Man, I know the feeling. It's rather annoying that the message does not
tell what is happening, not even the errno. I was thinking about having
the attached patch submitted, but I don't know if it's worth it.

In case of FC3, the most common problem is that udev somehow fails to start.
I do not know what the precise mechanics of it, because /dev/console
exists in initrd images, but with all the crazy root pivoting it's
no wonder it's ineffective. Anyhow, if udev quits, open in the init/main.c
will fail with ENOENT.

The only solution I know is to do everything over again, and make sure
you copied right configuration from /boot/config-2.6.9-1.678_FC3, and that
your mkinitrd run created a sensible initrd image. Verify that udev runs
and if not, debug that.

-- Pete

diff -urp -X dontdiff linux-2.6.10-rc2-bk8/init/main.c linux-2.6.10-rc2-bk8-usb/init/main.c
--- linux-2.6.10-rc2-bk8/init/main.c	2004-11-16 17:03:37.000000000 -0800
+++ linux-2.6.10-rc2-bk8-usb/init/main.c	2004-11-27 14:04:06.000000000 -0800
@@ -691,6 +691,8 @@ static inline void fixup_cpu_present_map
 
 static int init(void * unused)
 {
+	int rc;
+
 	lock_kernel();
 	/*
 	 * Tell the world that we're going to be the grim
@@ -738,8 +740,8 @@ static int init(void * unused)
 	system_state = SYSTEM_RUNNING;
 	numa_default_policy();
 
-	if (sys_open((const char __user *) "/dev/console", O_RDWR, 0) < 0)
-		printk("Warning: unable to open an initial console.\n");
+	if ((rc = sys_open((const char __user *) "/dev/console", O_RDWR, 0)) < 0)
+		printk("Warning: unable to open an initial console (%d).\n", rc);
 
 	(void) sys_dup(0);
 	(void) sys_dup(0);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


$B$3$N>pJs$,$"$J$?$NC5$7$F$$?$b$N$+$I$&$+A*Br$7$F$/$@$5$!#(B
yes/$B$^$5$K$3$l$@!*(B   no/$B0c$&$J$!(B   part/$B0lIt8+$D$+$C$?(B   try/$B$3$l$G;n$7$F$_$k(B

$B$"$J$?$,C5$7$F$$?>pJs$O$I$N$h$&$J$3$H$+!"$4<+M3$K5-F~2<$5$!#FC$K!V$^$5$K$3$l$@!*!W$H8@$&>l9g$O5-F~$r$*4j$$7$^$9!#(B
$BNc(B:$B!VJ#?t$N%^%7%s$+$i(BCATV$B7PM3$G(Bipmasquerade$B$rMxMQ$7$F(BWeb$B$r;2>H$7$?$>l9g$N@_Dj$K$D$$F!W(B