Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Dual mode (amd64 and x86) gentoo install disk
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
garlik42
n00b
n00b


Joined: 17 Dec 2002
Posts: 57
Location: Connecticut USA by the water ...

PostPosted: Mon Jul 31, 2006 6:26 pm    Post subject: Dual mode (amd64 and x86) gentoo install disk Reply with quote

Here is what I did to create a dual mode install disk.
This disk is used to do installs on emt64 and x86 architecture machines.

First I downloaded the 2 iso's and extracted all the files into 2 different directories.
I used the x86 disk as a base for the disk, and renamed (in the root) image.squashfs to image.x86.squashfs.
I then copied the image.squashfs from the emt64 disk to image.amd64.squashfs.
The root now looks like this:
Code:

Getting_Online.txt
README.txt
Readme.JD
files
image.amd64.squashfs
image.x86.squashfs
isolinux
livecd

files is a subdirectory I added, that has the script to build the disk, a portage snapshot and stage1 tarballs for both architechures.
Readme.JD is a file I use to track changes to the disk.
Next I went to the isolinux directory and did some more renaming (since I started with a 32 bit disk, these files are .... 32 bit!!)
ren gentoo gentoo.x86
ren gentoo.igz genx86.igz
I then copied files from the 64 bit /isolinux
copied gentoo to gentoo.a64
copied gentoo.igz to gena64.igz
I then edited the boot.msg to:
Code:

Gentoo Linux Installation LiveCD                         http://www.gentoo.org/
Combined amd64/x86 Livecd gentoo32 is default gentoo64 for amd64
Enter to boot; F1 for kernels  F2 for options.

I then copied the isolinux.cfg files from both disks, merged them and changed the filenames when nesessary
Code:

default gentoo32
timeout 150
prompt 1
display boot.msg
F1 kernels.msg
F2 F2.msg
F3 F3.msg
F4 F4.msg
F5 F5.msg
F6 F6.msg
F7 F7.msg

label gentoo32
  kernel gentoo.x86
  append root=/dev/ram0 init=/linuxrc  dokeymap looptype=squashfs loop=/image.x86.squashfs  cdroot initrd=genx86.igz vga=791 splash=silent,theme:livecd-2006.0 CONSOLE=/dev/tty1 quiet

label gentoo-nofb32
  kernel gentoo.x86
  append root=/dev/ram0 init=/linuxrc  dokeymap looptype=squashfs loop=/image.x86.squashfs  cdroot initrd=genx86.igz

label gentoo64
  kernel gentoo.a64
  append root=/dev/ram0 init=/linuxrc  dokeymap looptype=squashfs loop=/image.amd64.squashfs  cdroot initrd=gena64.igz vga=791 splash=silent,theme:livecd-2006.0 CONSOLE=/dev/tty1 quiet

label gentoo-nofb64
  kernel gentoo.a64
  append root=/dev/ram0 init=/linuxrc  dokeymap looptype=squashfs loop=/image.amd64.squashfs  cdroot initrd=gena64.igz

label memtest86
  kernel memtest86




The script I use to build the disk is
Code:

mkisofs -v -V "Gentoo Linux x86+amd64" -R -b isolinux/isolinux.bin -no-emul-boot -boot-load-size 4 -boot-info-table -c isolinux/boot.cat -iso-level 3 -o ../livecd.iso .

Here is a listing of all the files on the disk
Code:

.:
Getting_Online.txt  Readme.JD  image.amd64.squashfs*  isolinux/
README.txt          files/     image.x86.squashfs*    livecd

./files:
makecd.sh               stage1-amd64-2006.1.tar.bz2*
portage-2006.1.tar.bz2  stage1-x86-2006.1.tar.bz2*

./isolinux:
32bitisolinux.cfg  F3.msg  F6.msg    boot.msg*   gentoo.x86    isolinux.cfg
64bitisolinux.cfg  F4.msg  F7.msg    gena64.igz  genx86.igz    kernels.msg
F2.msg             F5.msg  boot.cat  gentoo.a64  isolinux.bin  memtest86



The whole disk is about 200 meg, and burns nicely on a mini cd.[/code]
_________________
#9252 xbox*2 PIII933dual Xeon3.4dual P4-3 426hemi
Back to top
View user's profile Send private message
yoshi314
l33t
l33t


Joined: 30 Dec 2004
Posts: 817
Location: PL

PostPosted: Thu Aug 03, 2006 8:02 am    Post subject: Reply with quote

you can save some cd space by using 64bit kernel with 32bit squashfs loopfile.
(it will work if the kernel has 32bit emulation (the ones from install cds have it enabled)

you can chroot into 64bit environment with no problems from a 32bit system ran with 64bit kernel. (sounds complicated :D)

this would need some extra work, however, because:

1. the 64bit squashfs image might hold some extra modules for 64bit kernel
2. the kernels would probably have the same version name and would expect their modules to be in the same dir. (when i build 64bit kernels, i add 64 at the end of their name, so that the modules directory would be different)

but that would be an overkill :]

nice job.
_________________
~amd64, ~x86
shrink your /usr/portage with squashfs+aufs
Back to top
View user's profile Send private message
garlik42
n00b
n00b


Joined: 17 Dec 2002
Posts: 57
Location: Connecticut USA by the water ...

PostPosted: Thu Aug 03, 2006 3:02 pm    Post subject: Reply with quote

Interesting idea, but one of my goals with this was to be able to independantly upgrade the 64 or 32 bit kernel/root.
By merging this would squash that ability.
As far as overkill, I'm all for it :-)

Thanks for the input.
_________________
#9252 xbox*2 PIII933dual Xeon3.4dual P4-3 426hemi
Back to top
View user's profile Send private message
yoshi314
l33t
l33t


Joined: 30 Dec 2004
Posts: 817
Location: PL

PostPosted: Mon Aug 07, 2006 6:51 pm    Post subject: Reply with quote

btw i saw a couple of weeks ago an archive that contained tools you could use to make a multi-livecd media.

i mean, you could take .e.g damn small linux, mepis, knoppix, etc etc. and throw them together onto one cd-r/dvd-r disc. on boot you would be presented with a menu of available distributions on the disc.

i don't remember where i found it, but i can upload it on some ftp if someone is interested. that would extend the presented method :]
_________________
~amd64, ~x86
shrink your /usr/portage with squashfs+aufs
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum