From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([69.77.167.62] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1KoiBO-0000jD-1k for garchives@archives.gentoo.org; Sat, 11 Oct 2008 17:23:14 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 89E4DE04D2; Sat, 11 Oct 2008 17:23:12 +0000 (UTC) Received: from wf-out-1314.google.com (wf-out-1314.google.com [209.85.200.173]) by pigeon.gentoo.org (Postfix) with ESMTP id 470D8E04D2 for ; Sat, 11 Oct 2008 17:23:12 +0000 (UTC) Received: by wf-out-1314.google.com with SMTP id 29so1080580wff.10 for ; Sat, 11 Oct 2008 10:23:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=569HHE92ARrOUG3CywGXt+VL30FLnY/vL64Qpd57PJI=; b=EPP1p58zmS8i0Xsn+d39oQbszO2bH4habGhwWj7bBiYtC9FX3rgekeIMvHZ0hb+wL8 kE8jGGKrDiXL+kz8Dpfc+OuSohnlPjPVb8GlEWRcbAmlO2q87wiILLSWDadXAEDDk5eC GCgUQrBWBAO23qSuhkkFsaJRefT/BFlLnex8U= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=iNrtrT36tJYQUti8ELyKW44OyjDzaL1GltxPmNA2ncQ1spUx11wXEBLHPHiOV3uwI1 ZldILFlRmsiij0eOknZb4BeQcfOlaDBnDU/jL9sje5+SxZYVEpRJbAYkSADued9x7D2p plW2NEgooGo4jVDKPzIAu3UcrUzHiu+2UhH7Q= Received: by 10.143.5.21 with SMTP id h21mr1541615wfi.175.1223745790538; Sat, 11 Oct 2008 10:23:10 -0700 (PDT) Received: by 10.143.40.6 with HTTP; Sat, 11 Oct 2008 10:23:10 -0700 (PDT) Message-ID: Date: Sat, 11 Oct 2008 13:23:10 -0400 From: "Andrey Vul" To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] Howto erase the "Insert root floppy and press enter" item before the kernel panic? In-Reply-To: <20081011080147.33a1916e@osage.osagesoftware.com> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20081010173408.c7cbe3a3.davidwei@newbread.tj.cn> <20081011113336.e42519a1.davidwei@newbread.tj.cn> <20081011080147.33a1916e@osage.osagesoftware.com> X-Archives-Salt: 72ba9669-9a71-4762-8359-9435eb0261a5 X-Archives-Hash: 7281937e3e908a6b8678e9d2c094012e On Sat, Oct 11, 2008 at 8:01 AM, David Relson wrote: > On Fri, 10 Oct 2008 23:06:09 -0400 > Andrey Vul wrote: > >> On Fri, Oct 10, 2008 at 10:33 PM, David Wei >> wrote: >> > Sorry, I forgot that file . >> > the .config is in the attachment this time. >> > Thank you . >> > >> > On Fri, 10 Oct 2008 10:05:36 -0400 >> > "Andrey Vul" wrote: >> > >> >> 2008/10/10 David Wei : >> >> > Hi, >> >> > I am trying kexec with "kernel panic reboot" cause i have to >> >> > manage my server remotely. the "kernel panic >> >> > reboot" (http://gentoo-wiki.com/TIP_Kernel_Panic_Reboot) has >> >> > beening working so good so far for the regular kernel >> >> > panic.However,sometimes when i were missed some file system >> >> > items,the booking process would ask me: "VFS: Unable to mount >> >> > root fs via NFS,trying floppy Insert root floppy and Press >> >> > Enter." And the system hungup there waiting for my Enter. How >> >> > can I remove this item from the booting process and panic >> >> > directly so that it can reboot? Besides,I want to keep the NFS >> >> > service. Thank you in advance. >> >> I'm guessing that this is due to the floppy being compiled into the >> >> emergency kernel. >> >> In any case, can you post your .config for the emergency kernel? >> >> >> >> Nothing in the .config looks suspicious. >> It looks like it's inevitable that kernel patching will be needed, at >> least, using the preprocessor to "hide" the floppy code. >> Try this (it comments out floppy support which happens after NFS >> support): comment_floppy.patch >> --- init/do_mounts.c 2008-04-16 22:49:44.000000000 -0400 >> +++ init/do_mounts2.c 2008-10-10 23:03:06.867876561 -0400 >> @@ -308,7 +308,8 @@ >> ROOT_DEV = Root_FD0; >> } >> #endif >> -#ifdef CONFIG_BLK_DEV_FD >> +/* #ifdef CONFIG_BLK_DEV_FD */ >> +#if 0 >> if (MAJOR(ROOT_DEV) == FLOPPY_MAJOR) { >> /* rd_doload is 2 for a dual initrd/ramload setup */ >> if (rd_doload==2) { >> >> cd to your /usr/src/linux-... and run patch -p0 < comment_floppy.patch >> It should fix the _specific_ issue. It might not fix the root cause, >> however. >> >> -- >> Andrey Vul > > Looking in do_mounts.c, the code that generates the message is: > > #ifdef CONFIG_ROOT_NFS > if (MAJOR(ROOT_DEV) == UNNAMED_MAJOR) { > if (mount_nfs_root()) > return; > > printk(KERN_ERR "VFS: Unable to mount root fs via NFS, trying floppy.\n"); > ROOT_DEV = Root_FD0; > } > #endif > > Looking at the .config file, I see "CONFIG_ROOT_NFS=y". Since the > message is being printed, we know that > > if (MAJOR(ROOT_DEV) == UNNAMED_MAJOR) > > is true which wmeans that the > > if (MAJOR(ROOT_DEV) == FLOPPY_MAJOR) > > is false, i.e. the change to "#if 0" looks to be incorrect. > > Perhaps "CONFIG_ROOT_NFS=y" in .config is the root cause. I'd suggest > changing the .config. He has explicity mentioned that his root device is NFS. You have misinterpreted the code. The floppy event only occurs *if* mount_nfs_root() failed. It's false from the start, but becomes true when NFS mount-root failed. -- Andrey Vul A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing in e-mail?