Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Gentoo ppc64 for iSeries
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC
View previous topic :: View next topic  
Author Message
kare
n00b
n00b


Joined: 06 Jun 2004
Posts: 26
Location: Friedberg, Germany

PostPosted: Sat Jun 12, 2004 3:51 pm    Post subject: Gentoo ppc64 for iSeries Reply with quote

Hello,

Pleased I read that Gentoo ppc64 becomes available also for iSeries. Since no pure 64bit version was available up to now, I could not expect it and tried an installation with the existing pSeries livecd (install-ppc64-pSeries-minimal-2004.1.iso.gz).
This was my first Gentoo installation and I was surprised that despite the necessary adjustments for iSeries it was so simple.
Here is a short description of the steps I did. I will not explain all those iSeries specific things, as interested people can find all details at IBM manuals and RedBooks.

Preparation

Linux on iSeries runs as guest OS in a logical partition. Within the native OS (OS/400) you have to create:
- a logical partition for Linux
- a network server description for Linux
- at least one network server storage for Linux - this storage holds the virtual disk spaces for the Linux OS. I created two of them, one (16GB) to install Gentoo Linux and one (200MB) to hold the livcd. Of course, you can burn the iso and use an iSeries cdrom if available, but it was more comfortably to have it on disk, in order to do quick modifications.

How to boot

You cannot boot Linux on iSeries from cdrom and you cannot use the pSeries kernel supplied with the livecd. I used my homemade kernel, built using one of the toolchains described at http://penguinppc64.org/.
Next I replaced kernel and modules on livecd and in initrd.img.gz (coming with livecd) with my own ones. It's also a good idea to change the terminal device names in inittab on livecd from ttyx to vcs/x. Now I could create a bootable image with my kernel and the Gentoo initrd.img.gz, using "addRamDisk" command (you can find it in the arch/ppc64 kernel tree). Booting Linux on iSeries is really easy and comfortable. Put your bootimage into IFS (this is an OS/400 filesystem), tell your Linux network server description which bootimage and boot options to use and start it. These are the options I've used:
IPLSTMF /gentoo/vmlinux-ge.ise -> name/location of the bootimage
IPLPARM devfs root=/dev/ram0 real_root=/dev/iseries/disc1/part1 -> this is the livecd copied to disk

How to connect to Linux

As the logical Linux partition has no physical console one must connect to a "virtual console", starting a telnet session at port 2301 to the OS/400 partition hosting Linux. I was surprised to see the kernel boot up to the login prompt already the first try. But root couldn't login both without password and with password.It took me some time hacking around to solve this problem. The virtual console device is named /dev/vcs/x (1-10) and I had to add an entry for it in /etc/securetty on livecd.

How to install

Simply follow the instructions of the Gentoo Linux/PPC Handbook. First of all I configured the network and started sshd, so I could connect using ssh. I decided to make a stage1 install and downloaded stage1-ppc64-20040519.tar.bz2 and one of the latest snapshots - portage-20040603.tar.bz2.
Those packages needed some modification to make them compile: sash, libperl and perl.
The rest of the system built without problem - and all of it 64bit.

Compile the kernel

No longer crosscompile - this system is now all 64bit. I took 2.6.6-r0, added my iSeries-config and built the 64bit-kernel.

Boot the new system

With Linux on iSeries you don't need to have a special boot partition and don't need to configure a bootloader. You can do it if you want (see the RedBooks), but it's not neccessary. Simply change the network server description on OS/400 and restart the Linux partition with the new options like this (don't forget to put the new kernel into IFS):
IPLSTMF /gentoo/vmlinux-2.6.6-r0-powerpc-iseries
IPLPARM devfs root=/dev/iseries/disc0/part1
Back to top
View user's profile Send private message
ezechiel_dantec
n00b
n00b


Joined: 14 Nov 2004
Posts: 32

PostPosted: Fri Jul 08, 2005 8:38 am    Post subject: Re: Gentoo ppc64 for iSeries Reply with quote

kare wrote:
Hello,


How to boot

You cannot boot Linux on iSeries from cdrom and you cannot use the pSeries kernel supplied with the livecd. I used my homemade kernel, built using one of the toolchains described at http://penguinppc64.org/.
Next I replaced kernel and modules on livecd and in initrd.img.gz (coming with livecd) with my own ones. It's also a good idea to change the terminal device names in inittab on livecd from ttyx to vcs/x. Now I could create a bootable image with my kernel and the Gentoo initrd.img.gz, using "addRamDisk" command (you can find it in the arch/ppc64 kernel tree). Booting Linux on iSeries is really easy and comfortable. Put your bootimage into IFS (this is an OS/400 filesystem), tell your Linux network server description which bootimage and boot options to use and start it. These are the options I've used:
IPLSTMF /gentoo/vmlinux-ge.ise -> name/location of the bootimage
IPLPARM devfs root=/dev/ram0 real_root=/dev/iseries/disc1/part1 -> this is the livecd copied to disk


Would it be possible to have a more complete description of this step, please, since we intend to do the same thing on our next iSeries server in our company? The more details, the easier it will be for us to install Gentoo :)
Back to top
View user's profile Send private message
kare
n00b
n00b


Joined: 06 Jun 2004
Posts: 26
Location: Friedberg, Germany

PostPosted: Fri Jul 08, 2005 7:08 pm    Post subject: Reply with quote

I will try to write a more detailed how to do in the next days.
Using the latest install-ppc64-ibm-minimal-2005.0.iso there are only a few changes necessary, but firstly you need to have a 64bit kernel
built for iSeries.
You also can have my kernels and/or complete iSeries prepared iso. It's built and running on a model 840 and I don't know if it will install
on a newer i5 model.
Back to top
View user's profile Send private message
ezechiel_dantec
n00b
n00b


Joined: 14 Nov 2004
Posts: 32

PostPosted: Fri Jul 08, 2005 10:22 pm    Post subject: Thanks Reply with quote

I'll ask what model we'll have and tell you asap (monday probably).
Back to top
View user's profile Send private message
kare
n00b
n00b


Joined: 06 Jun 2004
Posts: 26
Location: Friedberg, Germany

PostPosted: Fri Jul 15, 2005 6:10 pm    Post subject: Reply with quote

ezechiel_dantec, here ist a more detailed description, which you asked for:

ppc64 kernel for iSeries
First of all you must have a ppc64 kernel built for iSeries.
It's another story how to build it, if you don't have Linux already running on iSeries.

Bootable image
- get install-ppc64-ibm-minimal-2005.0.iso from Gentoo mirror
- mount -o loop install-ppc64-ibm-minimal-2005.0.iso /mnt
- cp /mnt/initrd-pSeries.img.gz /work
- cd /work
- gunzip initrd-pSeries.img.gz
- mount -o loop initrd-pSeries.img /img
- rm -rf /img/lib/modules/2.6.11-pSeries
- mkdir /img/lib/modules/2.6.11-iSeries
- cp /lib/modules/2.6.11-iSeries/modules.* /img/lib/modules/2.6.11-iSeries
- umount /img
- mv initrd.pSeries.img initrd.iSeries.img
- gzip -9 initrd.iSeries.img
- addRamDisk initrd.iSeries.img.gz System.map-2.6.11-iSeries vmlinux-2.6.11-iSeries vmlinux-ge611.ise
(this step builds a bootable image using your kernel and the Gentoo initrd)

INSTALL IMAGE
- copy /mnt/* to /newimg
- remove from /newimg/boot all pSeries stuff
- add to /newimg/boot (not really necessary, because we will boot from ifs):
System.map-2.6.11-iSeries
config-2.6.11-iSeries
vmlinux-2.6.11-iSeries
vmlinux-ge611.ise
- remove from /newimg/etc/kernels all pSeries stuff
- add to /newimg/etc/kernels:
kernel-config-ppc64-2.6.11-iSeries
- change /newimg/etc/inittab
tty1-6 becomes vcs/1-6
- add to /newimg/etc/securetty
vcs/1-12
- create iso file from /newimage and burn your ISERIES cd


Install on iSeries

either - if you have access to cdrom on your iSeries
- boot install image from cdrom
create network server storage
gentoo: CRTNWSSTG NWSSTG(GENTOO) NWSSIZE(16000) FORMAT(*OPEN)
create network server description gentoo and set:
IPL-Datenstromdatei . . . . . . . : /QOPT/ISERIES/vmlinux-ge611.ise
IPL-Parameter . . . . . . . . . . : devfs root=/dev/ram0 real_root=/dev/iseries/vcd0
add network server storage link
ADDNWSSTGL NWSSTG(GENTOO) NWSD(GENTOO) DRVSEQNBR(1)

or - if you have no cdrom access on your iSeries
- boot install image from network server storage
create network server storage
gentoo: CRTNWSSTG NWSSTG(GENTOO) NWSSIZE(16000) FORMAT(*OPEN)
install image: CRTNWSSTG NWSSTG(INST20050) NWSSIZE(600) FORMAT(*OPEN)
create network server description gentoo and set:
IPL-Datenstromdatei . . . . . . . : /gentoo/vmlinux-ge611.ise
IPL-Parameter . . . . . . . . . . : devfs root=/dev/ram0 real_root=/dev/iseries/disc1/part1
add network server storage link
ADDNWSSTGL NWSSTG(GENTOO) NWSD(GENTOO) DRVSEQNBR(1)
ADDNWSSTGL NWSSTG(INST20050) NWSD(GENTOO) DRVSEQNBR(2)
Transfer the contents of the install image to the network server storage INST20050.
Maybe you need to have already installed another Linux on your iSeries to do this.
Let me know if you need help with this step - there are some possible workarounds.

- transfer from install image to ifs
/gentoo/vmlinux-ge611.ise
/gentoo/vmlinux-2.6.11-iSeries

- telnet to the iSeries hosting partition on port 2301
- vary on the nwsd gentoo and enjoy Gentoo booting on iSeries
- follow the Gentoo installation manual
- emerge the following packages after bootstrapping:
baselayout, net-tools, ssh, udev, slocate, metalog, mc

Boot the installed system
- change network server description gentoo:
IPL-Datenstromdatei . . . . . . . : /gentoo/vmlinux-2.6.11-iSeries
IPL-Parameter . . . . . . . . . . : root=/dev/iseries/vda1
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on PPC 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