LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-09-2007, 07:01 PM   #1
wsanders
Member
 
Registered: Jul 2003
Posts: 31

Rep: Reputation: 15
Tool for building net booted kernel and ramdisk?


I am exploring further options for net booting and kickstart.

The process I want to use is:

1) Boot via PXE, got it working using pxelinux and grub.

2) Load the Magic Mother Of All Kernels and Initrd's

3) Kickstart - got it working sort of, booting from CDROM. Seems straightforward.

Steps 1 and 3 seem to be covered. But step 2 is a mystery. I've located no real documentation or tools.

I'm not a terribly experienced kernel builder and completely INexperienced at coming up with initrd's. I suppose after days of trial and error that I could come up with something that would work. So far, all the kernels I've tried panic.

I'm using Fedora but I'm not OS-centric. If it's 10 times easier with some other distro I'm open to suggestions. Theoretically, I should even be able to boot distro X and use it to kickstart distro Y ....

TIA, just a quick pointer in the wilderness will be appreciated.

-W Sanders
 
Old 05-11-2007, 10:50 AM   #2
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
Does this help?
 
Old 05-11-2007, 01:35 PM   #3
wsanders
Member
 
Registered: Jul 2003
Posts: 31

Original Poster
Rep: Reputation: 15
in the right direction (a plug for Solaris 10)

although I would replace the phrase "surprising amount of fiddling" with "appalling amount of fiddling".

The Sun blueprint he links to describes setting up a Jumpstart server to install Solaris x86 via PXE. I've actually done that, it's *easy*, and actually a big reason to run Solaris 10 rather than Linux on X86; the net boot / disaster recovery capabilities of Sol 10 are MUCH more rebust than (the freely available) Linux. (at least I know, HP, and IBM have their own proprietary tools, for blades etc. HP's actually require a windows server.

The variation on the Sun doc is I used the ISC DHCP server, which is much easier to figure out than Solaris's. Basically the steps are:

1) Create a bog-standard Solaris Jumpstart server, "setup_install_server", yadda yadda yadda. (This is in that Sun Blueprint.)

2) Build and install the ISC DHCPD with conf file lines something like this:

Code:
ddns-update-style none;
allow bootp;
allow booting;
subnet 10.10.20.0 netmask 255.255.255.0 {
        option routers 10.10.20.1;
        option domain-name-servers 10.10.0.34;
        }
group { 
# THIS IS THE GROUP THAT JUMPSTART WILL MAKE FOR YOU
# It uses Grub
       next-server 10.10.20.41;
       filename "pxegrub.I86PC.Solaris_10-1";
       host foo {
               hardware ethernet 00:d0:b7:c7:67:d8;
               fixed-address 10.10.20.200;
               }
}
# OR (Comment the other group out)
group {
# THIS GROUP USES PXELINUX 
        next-server 10.10.20.41;
        filename "pxelinux.0";
        host foo {
                hardware ethernet 00:d0:b7:c7:67:d8;
                fixed-address 10.10.20.200;
                }
}

/tftpboot/boot/grub/menu.lst:

default=0
timeout=10
title Solaris_10 Jumpstart
        kernel /I86PC.Solaris_10-1/multiboot kernel/unix -B
install_config=10.10.20.41:/js/jumpstart/yipes,sysid_config=10.10.20.41:/js/jump
start/yipes/Sysidcfg/Solaris_10_.nm24,install_media=10.10.20.41:/js/os/sol-10-u1
-ga-x86,install_boot=10.10.20.41:/js/os/sol-10-u1-ga-x86/boot -m install
       module /I86PC.Solaris_10-1/x86.miniroot
title I AM A JELLY DONUT
        kernel /FC4/vmlinuz-2.6.11-1.1369_FC4
        append  load_ramdisk=1 initrd=initrd-2.6.11-1.1369_FC4.img 

/tftpboot/0A0A14C8: (host's MAC addr in HEX)

default linux
label linux
        kernel FC4/<<some magic kernel>>
        append ksdevice=eth0 console=tty0 load_ramdisk=1
initrd=<<some magic initrd>> network
Of course you could boot Solaris with pxelinux and FC4 with Grub, yadda, yadda, yadda.

Where I am hung up is creating the <<some magic kernel>> and <<some magic initrd>>.
 
Old 05-11-2007, 06:19 PM   #4
wsanders
Member
 
Registered: Jul 2003
Posts: 31

Original Poster
Rep: Reputation: 15
Giving up on netbooting Fedora for now

Code:
[root@blah kernels]# cd  2.6.17-1.2142_FC4-i686
[root@blah 2.6.17-1.2142_FC4-i686]# make
.....
# using defaults found in .config
#
 ....
make[1]: *** No rule to make target `init/main.o', needed by `init/built-in.o'.  Stop.
make: *** [init] Error 2
Giving up on FC4 - sigh.


See below for better answer.

Last edited by wsanders; 06-06-2007 at 06:08 PM.
 
Old 05-12-2007, 10:42 AM   #5
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
You have to configure the kernel before you make it. Try reading something like this. I think that doc is missing some stuff though. If you're using a 2.6 series, you don't have to have the symlink to /usr/src. You can build it pretty much anywhere. I have a ~/src directory that I use to build all my kernels. Also, I have found it's easier to use make xconfig instead of make menuconfig if you are running X.
I could probably write a short book on building a kernel, but I'll try to keep it somewhat short. Basically, you can either use the kernel source included in your distro or just get it from kernel.org. When you do make xconfig (if that is what you use), you can actually load up your .config from your running kernel so you don't have to go through and pick all the modules you want. The nice thing about make xconfig is that it tells a little about each option, so if you aren't sure about something, it explains it a bit.

Last edited by manwichmakesameal; 05-12-2007 at 10:47 AM.
 
Old 05-14-2007, 12:35 PM   #6
wsanders
Member
 
Registered: Jul 2003
Posts: 31

Original Poster
Rep: Reputation: 15
Yep, no trouble bulding a kernel.org kernel, it's the FC4 kernel src package that's broken. You can do make menuconfigs until you are blue in the face but they will all fail with the same make error deep in the morass of the nested Makefiles. I'm not enough of a make expert anymore to debug this or even tell if I'm just missing something obvious. Plus, all the RedHat releases and variants are supposed to come with a .config file that was used to build the distro's kernel, and installing the kernel src USED to rebuild the kernel at rpm install time using those parameters.

Just a headsup that the FC4 kernel seems broken. Last year's news to everyone, probably. I only used FC4 because I had the CDs around and FC6 has bloated up to 6 CDs.


See below for better answer.

Last edited by wsanders; 06-06-2007 at 06:07 PM.
 
Old 06-06-2007, 06:06 PM   #7
wsanders
Member
 
Registered: Jul 2003
Posts: 31

Original Poster
Rep: Reputation: 15
The question I was asking had so glaringly obvious an answer that everyone overlooked it because the kernel and initrd I needed were lying out in plain sight: On the release CDROM! In either <CD>/images/pxeboot and in <CD>/isolinux. D'oh!

Now I'm net-installing away, and the install server is running Solaris, even. Let the boring, endless kickstart tweaking commence.

Last edited by wsanders; 06-06-2007 at 06:09 PM.
 
  


Reply

Tags
initrd, kernel, kickstart



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Failed to find suitable ramdisk generation tool for kernel version sycamorex Linux - Kernel 6 05-05-2007 11:08 PM
Building a Tool Chain yugandhar Linux - Kernel 3 12-16-2006 05:45 PM
No suitable ramdisk generation tool ? mfakbulut Linux - Newbie 3 01-05-2006 12:26 PM
Building a file system ( Ramdisk) ayoub Linux - Newbie 1 11-10-2005 08:48 PM
building kde... glib, pkg-tool wtf? miko3k Linux - Software 2 06-21-2005 10:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration