Mailing List Archive

2-stage boot process
I can't seem to get my remote hosted machine to boot to a kernel that
isn't vanilla. My host says he always uses vanilla kernels on his
machines. He is suggesting:

Have you thought about trying to use an initrd at boot up? It almost
seems like there needs to be some driver for booting that isn't loaded
as the kernel tries to boot, and maybe using a 2-stage boot process
may help.

I don't know what that means at all, and I'm wondering what you guys
think about trying that?

Here's lspci if anyone is interested:

livecd / # lspci
0000:00:00.0 Host bridge: VIA Technologies, Inc. P4M266 Host Bridge
0000:00:01.0 PCI bridge: VIA Technologies, Inc. VT8633 [Apollo Pro266 AGP]
0000:00:05.0 Ethernet controller: D-Link System Inc RTL8139 Ethernet (rev 10)
0000:00:10.0 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
1.1 Controller (rev 80)
0000:00:10.1 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
1.1 Controller (rev 80)
0000:00:10.2 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
1.1 Controller (rev 80)
0000:00:10.3 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 82)
0000:00:11.0 ISA bridge: VIA Technologies, Inc. VT8235 ISA Bridge
0000:00:11.1 IDE interface: VIA Technologies, Inc.
VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
0000:00:11.5 Multimedia audio controller: VIA Technologies, Inc.
VT8233/A/8235/8237 AC97 Audio Controller (rev 50)
0000:00:12.0 Ethernet controller: VIA Technologies, Inc. VT6102
[Rhine-II] (rev 74)
0000:01:00.0 VGA compatible controller: S3 Inc. VT8375 [ProSavage8 KM266/KL266

- Grant

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
Is this a clean Gentoo install, or was the machine previously run on
another distro (ie. Fedora, RedHat)?

My experience with Gentoo running on a machine that was previously
Fedora/RedHat is that 2.6 kernels won't work. There's a kernel panic
with VFS when mounting the root partition.


On Thu, 9 Sep 2004 17:28:34 +0000, Grant <emailgrant@gmail.com> wrote:
> I can't seem to get my remote hosted machine to boot to a kernel that
> isn't vanilla. My host says he always uses vanilla kernels on his
> machines. He is suggesting:
>
> Have you thought about trying to use an initrd at boot up? It almost
> seems like there needs to be some driver for booting that isn't loaded
> as the kernel tries to boot, and maybe using a 2-stage boot process
> may help.
>
> I don't know what that means at all, and I'm wondering what you guys
> think about trying that?
>
> Here's lspci if anyone is interested:
>
> livecd / # lspci
> 0000:00:00.0 Host bridge: VIA Technologies, Inc. P4M266 Host Bridge
> 0000:00:01.0 PCI bridge: VIA Technologies, Inc. VT8633 [Apollo Pro266 AGP]
> 0000:00:05.0 Ethernet controller: D-Link System Inc RTL8139 Ethernet (rev 10)
> 0000:00:10.0 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
> 1.1 Controller (rev 80)
> 0000:00:10.1 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
> 1.1 Controller (rev 80)
> 0000:00:10.2 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB
> 1.1 Controller (rev 80)
> 0000:00:10.3 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 82)
> 0000:00:11.0 ISA bridge: VIA Technologies, Inc. VT8235 ISA Bridge
> 0000:00:11.1 IDE interface: VIA Technologies, Inc.
> VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
> 0000:00:11.5 Multimedia audio controller: VIA Technologies, Inc.
> VT8233/A/8235/8237 AC97 Audio Controller (rev 50)
> 0000:00:12.0 Ethernet controller: VIA Technologies, Inc. VT6102
> [Rhine-II] (rev 74)
> 0000:01:00.0 VGA compatible controller: S3 Inc. VT8375 [ProSavage8 KM266/KL266
>
> - Grant
>
> --
> gentoo-user@gentoo.org mailing list
>
>

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
Grant (emailgrant@gmail.com) scribbled:
> I can't seem to get my remote hosted machine to boot to a kernel that
> isn't vanilla. My host says he always uses vanilla kernels on his
> machines. He is suggesting:
>
> Have you thought about trying to use an initrd at boot up? It almost
> seems like there needs to be some driver for booting that isn't loaded
> as the kernel tries to boot, and maybe using a 2-stage boot process
> may help.
>
> I don't know what that means at all, and I'm wondering what you guys
> think about trying that?

There should be no need. Can you post a dmesg output or screen dump of
the errors that cause the kernel panic? Most likely some driver is
compiled as a module and it needs to be compiled into the kernel.
initrd's solve this by making a special 'mini-root' that has the modules
available to the kernel (as well as some other stuff). If you compile
the module in, this shouldn't be necessary.

hth,

Cooper.

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thursday 09 September 2004 19:04, Jason Cooper wrote:

> There should be no need. Can you post a dmesg output or screen dump of
> the errors that cause the kernel panic? Most likely some driver is
> compiled as a module and it needs to be compiled into the kernel.
> initrd's solve this by making a special 'mini-root' that has the modules
> available to the kernel (as well as some other stuff). If you compile
> the module in, this shouldn't be necessary.

An initrd is also a pain in the ass, as you have to keep 2 copies of modules.
Years ago, when RAM was expensive, initrds would have been useful to keep
kernel memory usage down, but do you really care if your kernel is 1-200K
bigger?
This only really applies to self-compiled kernels, as generic kernels
obviously have to support vastly differing hardware. They would be freaking
huge if they contained every driver available!

Genkernel makes it easy though.

Getting back to Grants problem though.
You want, at least, compiled into the kernel:
VIA IDE
& fs drivers for your / and /boot filesystems.

You could compile Realtek 8139 and VIA Rhine nic drivers in, or as modules and
load them with /etc/modules.autoload.d/kernel-2.x to have more control over
which is eth0 and eth1.

For such simple hardware use any kernel you want.

- --
Mike Williams
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFBQKytInuLMrk7bIwRAh4XAJ9ut4F/LOUMfrJb2syQTEXAYpWAHwCfXlWn
0BZxnlJX6/4D+F36RbsA/lI=
=OrsD
-----END PGP SIGNATURE-----

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
Mike Williams wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Thursday 09 September 2004 19:04, Jason Cooper wrote:
>
>
>>There should be no need. Can you post a dmesg output or screen dump of
>>the errors that cause the kernel panic? Most likely some driver is
>>compiled as a module and it needs to be compiled into the kernel.
>>initrd's solve this by making a special 'mini-root' that has the modules
>>available to the kernel (as well as some other stuff). If you compile
>>the module in, this shouldn't be necessary.
>
>
> An initrd is also a pain in the ass, as you have to keep 2 copies of modules.
> Years ago, when RAM was expensive, initrds would have been useful to keep
> kernel memory usage down, but do you really care if your kernel is 1-200K
> bigger?
> This only really applies to self-compiled kernels, as generic kernels
> obviously have to support vastly differing hardware. They would be freaking
> huge if they contained every driver available!
>
> Genkernel makes it easy though.
>
> Getting back to Grants problem though.
> You want, at least, compiled into the kernel:
> VIA IDE
> & fs drivers for your / and /boot filesystems.
>
> You could compile Realtek 8139 and VIA Rhine nic drivers in, or as modules and
> load them with /etc/modules.autoload.d/kernel-2.x to have more control over
> which is eth0 and eth1.
>
> For such simple hardware use any kernel you want.

Some time ago, there way a robust discussion on CFLAGS settings.
Some of the responders were very happy with CFLAGS="-Os" for small...

I think VIA was one of the boards that seemed to perform well,
according to one of the responders, if memory is not corrupt.....YMMV

Maybe check the archives, as my mem is aging and of the vintage sort....

James


--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Thu, 9 Sep 2004 14:04:59 -0400, Jason Cooper <gentoo@lakedaemon.net> wrote:
> Grant (emailgrant@gmail.com) scribbled:
> > I can't seem to get my remote hosted machine to boot to a kernel that
> > isn't vanilla. My host says he always uses vanilla kernels on his
> > machines. He is suggesting:
> >
> > Have you thought about trying to use an initrd at boot up? It almost
> > seems like there needs to be some driver for booting that isn't loaded
> > as the kernel tries to boot, and maybe using a 2-stage boot process
> > may help.
> >
> > I don't know what that means at all, and I'm wondering what you guys
> > think about trying that?
>
> There should be no need. Can you post a dmesg output or screen dump of
> the errors that cause the kernel panic? Most likely some driver is
> compiled as a module and it needs to be compiled into the kernel.
> initrd's solve this by making a special 'mini-root' that has the modules
> available to the kernel (as well as some other stuff). If you compile
> the module in, this shouldn't be necessary.
>
> hth,
>
> Cooper.

Here's what my host says happens before the big freeze:

---
root (hd0,0)
File system type is ext2fs, partition type 0x83
kernel /kernel-2.4.27-hardened-r1 root=/dev/hda3
[Linux-bzImage, setup=0xa00, size=0xc24ff]

Uncompressing Linx... Ok, booting the kernel.
---

I actually didn't compile a single thing as a module. It was either on or off.

- Grant

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Thu, 9 Sep 2004 20:19:07 +0100, Mike Williams <mike@gaima.co.uk> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Thursday 09 September 2004 19:04, Jason Cooper wrote:
>
> > There should be no need. Can you post a dmesg output or screen dump of
> > the errors that cause the kernel panic? Most likely some driver is
> > compiled as a module and it needs to be compiled into the kernel.
> > initrd's solve this by making a special 'mini-root' that has the modules
> > available to the kernel (as well as some other stuff). If you compile
> > the module in, this shouldn't be necessary.
>
> An initrd is also a pain in the ass, as you have to keep 2 copies of modules.
> Years ago, when RAM was expensive, initrds would have been useful to keep
> kernel memory usage down, but do you really care if your kernel is 1-200K
> bigger?
> This only really applies to self-compiled kernels, as generic kernels
> obviously have to support vastly differing hardware. They would be freaking
> huge if they contained every driver available!
>
> Genkernel makes it easy though.
>
> Getting back to Grants problem though.
> You want, at least, compiled into the kernel:
> VIA IDE
> & fs drivers for your / and /boot filesystems.
>
> You could compile Realtek 8139 and VIA Rhine nic drivers in, or as modules and
> load them with /etc/modules.autoload.d/kernel-2.x to have more control over
> which is eth0 and eth1.
>
> For such simple hardware use any kernel you want.
>
> - --
> Mike Williams

Mike,

Is this what you mean by VIA IDE:

VIA82CXXX chipset support (NEW)

That option is presented once I turn on PCI IDE chipset support and I
did not have that option turned on before. I do think I've tried it
before, but maybe not.

The only stuff I have enabled under File Systems:

ext3, virtual memory, ISO9660, /proc, /proc/config, /dev,
automatically mount at boot

Both / and /boot are ext3.

I compiled support for the Rhine NIC in, and I have to admit I don't
know if I'm hooked up to that or the Realtek, but I figure it isn't
even time to worry about that yet.

- Grant

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
Grant wrote:

>On Thu, 9 Sep 2004 14:04:59 -0400, Jason Cooper <gentoo@lakedaemon.net> wrote:
>
>
>>Grant (emailgrant@gmail.com) scribbled:
>>
>>
>>>I can't seem to get my remote hosted machine to boot to a kernel that
>>>isn't vanilla. My host says he always uses vanilla kernels on his
>>>machines. He is suggesting:
>>>
>>>Have you thought about trying to use an initrd at boot up? It almost
>>>seems like there needs to be some driver for booting that isn't loaded
>>>as the kernel tries to boot, and maybe using a 2-stage boot process
>>>may help.
>>>
>>>I don't know what that means at all, and I'm wondering what you guys
>>>think about trying that?
>>>
Try genkernel.

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
It appears that on Sep 11 2004 at 18:10:08, Grant wrote ...
> The only stuff I have enabled under File Systems:
>
> ext3, virtual memory, ISO9660, /proc, /proc/config, /dev,
> automatically mount at boot
>
> Both / and /boot are ext3.
>

I think that you also need to compile in support for ext2



--

Ash Varma
tnedor@yahoo.com

It's all GNU to me.

-- From a Slashdot.org post

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sunday 12 September 2004 01:53, Grant wrote:

> Here's what my host says happens before the big freeze:
>
> ---
> root (hd0,0)
> File system type is ext2fs, partition type 0x83
> kernel /kernel-2.4.27-hardened-r1 root=/dev/hda3
> [Linux-bzImage, setup=0xa00, size=0xc24ff]
>
> Uncompressing Linx... Ok, booting the kernel.
> ---

If it did nothing else I suspect you're missing CONFIG_VT, virtual terminal
support, so you won't be able to see what is stopping it from booting
properly.
Even without support for virtual terminals it's perfectly possible for it to
work fine, but you'll only be able to use it remotely :)

Don't take this the wrong way, but as you had turned IDE support off, I reckon
you'd be better off using genkernel, as Mark suggested. It will give you a
solid base config to work from.

genkernel --menuconfig kernel

Then selectively turn off those things you're *sure* you don't need, and
either compile your NIC drivers into the kernel, or make sure you add them to
the appropriate /etc/modules.autoload.d/kernel-2.x file.

- --
Mike Williams
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.9.10 (GNU/Linux)

iD8DBQFBRKSQInuLMrk7bIwRAh9kAJ4wzmWQ2Edef6MX5yeLP5PETgkWCgCfaUCx
NGMkahj/NLLQgYvzMvu+4iY=
=+KwW
-----END PGP SIGNATURE-----

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Sun, 12 Sep 2004 20:33:20 +0100, Mike Williams <mike@gaima.co.uk> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On Sunday 12 September 2004 01:53, Grant wrote:
>
> > Here's what my host says happens before the big freeze:
> >
> > ---
> > root (hd0,0)
> > File system type is ext2fs, partition type 0x83
> > kernel /kernel-2.4.27-hardened-r1 root=/dev/hda3
> > [Linux-bzImage, setup=0xa00, size=0xc24ff]
> >
> > Uncompressing Linx... Ok, booting the kernel.
> > ---
>
> If it did nothing else I suspect you're missing CONFIG_VT, virtual terminal
> support, so you won't be able to see what is stopping it from booting
> properly.
> Even without support for virtual terminals it's perfectly possible for it to
> work fine, but you'll only be able to use it remotely :)
>

OK, I'll try turning that on so I can get more information about the crash.

> Don't take this the wrong way, but as you had turned IDE support off, I reckon
> you'd be better off using genkernel, as Mark suggested. It will give you a
> solid base config to work from.
>

Do you mean PCI IDE support? I have that disabled on my desktop and
it works fine. Does something from my lspci make you think I need it?

- Grant

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Sunday 12 September 2004 22:03, Grant wrote:
> > Don't take this the wrong way, but as you had turned IDE support off, I
> > reckon you'd be better off using genkernel, as Mark suggested. It will
> > give you a solid base config to work from.
>
> Do you mean PCI IDE support? I have that disabled on my desktop and
> it works fine. Does something from my lspci make you think I need it?

Yes, this line:
0000:00:11.1 IDE interface: VIA Technologies, Inc.
VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)

It's an IDE controller.
Is your desktop system SCSI based?
If not, out of interest, what does 'hdparm -t /dev/hdX' say? A semi-modern
system should be well over 15MB/sec. My 3 year old laptop does 15-16MB/sec.

--
Mike Williams

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Sun, 12 Sep 2004 22:53:03 +0100, Mike Williams <mike@gaima.co.uk> wrote:
> On Sunday 12 September 2004 22:03, Grant wrote:
> > > Don't take this the wrong way, but as you had turned IDE support off, I
> > > reckon you'd be better off using genkernel, as Mark suggested. It will
> > > give you a solid base config to work from.
> >
> > Do you mean PCI IDE support? I have that disabled on my desktop and
> > it works fine. Does something from my lspci make you think I need it?
>
> Yes, this line:
> 0000:00:11.1 IDE interface: VIA Technologies, Inc.
> VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
>
> It's an IDE controller.
> Is your desktop system SCSI based?
> If not, out of interest, what does 'hdparm -t /dev/hdX' say? A semi-modern
> system should be well over 15MB/sec. My 3 year old laptop does 15-16MB/sec.
>
> --
> Mike Williams

Mike,

The system is not SCSI-based. Here is the hdparm output:

---
livecd / # hdparm -t /dev/hda3

/dev/hda3:
Timing buffered disk reads: 158 MB in 3.01 seconds = 52.49 MB/sec
---

When my host is available to remove the LiveCD tomorrow I will:

1. enable the virtual terminal to get more crash info
2. enable PCI IDE and the VIA option
3. enable ext2 support (my filesystems are all ext3 though)

I should have mentioned that I was trying to get gs-sources to work
before I moved to hardened-sources and my host actually tried to
configure that kernel for me and couldn't get it to boot either. So
far vanilla from kernel.org has been the only successful one.

After I make these changes to the current kernel, should I be able to
do the following from /usr/src/linux and reboot without doing anything
else:

make dep && make bzImage modules modules_install
make install

I've had trouble getting make install to work right in the past, but
I'd like to use it. It seems pretty slick. Also, I use grub.

- Grant

P.S. Thanks a lot to everyone for their attention. This problem is
keeping me from launching my new store, and I'm VERY eager to do that.

--
gentoo-user@gentoo.org mailing list
Re: 2-stage boot process [ In reply to ]
On Sun, 12 Sep 2004 22:25:06 +0000, Grant <emailgrant@gmail.com> wrote:
> P.S. Thanks a lot to everyone for their attention. This problem is
> keeping me from launching my new store, and I'm VERY eager to do that.

I got it booting! Thanks for eveyone's help. Once I pinpoint what
was keeping it from booting before I'll post it here.

- Grant

--
gentoo-user@gentoo.org mailing list