How to install Linux/Debian PPC on a Pegasos ?


by DET Nicolas, Last update: January 28th 2003


Index :



1) Introduction


1.1 DISCLAIMER


This howto is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Even, if you lose all you data, if your computer is break down, I would not be responsible in any case !

1.2 What is Linux ?


Linux is an OpenSource multi-user operating system. It had become very popular for some years. Linux has many interesting features:

But there are also some weak points:
There would be a very lot of to say about Linux. For more information, visit linux.org

1.3 Requirment


Before installting Linux/debian, you will need th following:

You have everything ! Let's continue !

2) Preparation


First, serious stuff !

2.1 Create boot disk


Be sure, you have a floppy drive, and Debian CD1
You also need another computer because there is no floppy drive support in MorphOS at present.

On Linux,
On Windows,

2.2 Prepare your HD on MorphOS


First, beware, using SCSIconfig can be dangerous ! I lost my RDB once !
I advise you, to have a MorphOS boot CD ready, as well as the sys:tools/SCSConfig.RDBstorage somewhere ( you can print it). With that you can recover your RDB.

In SCSIConfig, you have to make 2 partitions. One for Linux itself, the other for the swap.
For the Linux one, you need at least 2Gb, choose custom file system, and insert "0x4c4e5800".
For the swap one, you need at least 200Mb, choose custom filesystem, and insert "0x53575000".

Now, note "where" your Linux partitions are. It is very important for the next step.
Example: your hard disk is on ide.device unit 0 and like that:
DH0: FFS
DH1: FFS
DH2: SFS
DH3: SFS
DH4: SFS
DH5: Linux
DH6: Linux
DH7: Swap
For Linux, the ext2fs partition If you HD is on unit 0 -> /dev/hda6.

/dev/hda -> unit 0
/dev/hdb -> unit 1
/dev/hdc -> unit 2
/dev/hdd -> unit 3


for SCSI:
/dev/sda -> unit 0 ...

3)Installation


3.1 The first boot


Now, that we have everything to install Linux. Let's go !


Now, it should load the kernel, and then load the root filesystem. Just wait ...

3.2 Base system installation


Once Linux has boot, you will be in front of the Debian installer. It will lead you during the base system installation process. However, it is designed more or less for a PC, and we don't use PC here. Therefore, we will have to perform some operations by hand.

First, it should ask you to select your language, do so !

Some information about Linux/Debian, just press

Keyboard: You should choose qwerty/us because I suppose you use a PS/2 keyboard, and it is the only non-USB keyboard. We will select the good keymap later, don't be afraid !

Machine Name: Now, the installer asks you for you machine name. It will show up when you login. However it is no very important, especially if you don't have any network. I put "Pegasos".

DHCP: Is your IP configure automatically or not ? If you don't care about network, select no and default value.
->YES: It should detect everything you need.
->NO: Just setup your network (IP, mask ...)

Partitions: Humm, we will have to do some operations by hand, because the installer does not know how to handle Amiga-style partition.
type: ALT+F2
Your are now in a light Unix-style shell.

>WARNING !! THIS IS DANGEROUS ! IF YOU TYPE SOMETHING WRONG YOU MIGHT LOS DATA !!!!<
So be careful, and always check what you are doing !


The partition you have to format is the one you have configured in SCSIConfig.

To format your Linux partition type: >mke2fs /dev/xxx (example: I put >mkde2fs /dev/hda6).BE VERY CAREFULL !!!
To make your swap partition: >mkswap /dev/yyy BE CAREFULL !!!
Let's activate the swap: >swapon -c /dev/yyy
Now, we will mount the "target" parition (aka where Debian will be installed): > mount /dev/xxx /target
Put the Debian CDROM in the drive.

Let's Continue: Go back into the installer with ALT+F1. And select "Kernel & module isntallation", "NO", and "Cancel"

Then select "Install base system", CDROM, "/instmnt" -> OK


It will take some time, so be patient...

When this operation is finished, unmount /target: ALT+F2, >umount /target.
Now, just "reboot your machine" (ALT+F1 -> select reboot in the installer menu first).

3.3 How to boot on Linux


Now, that you have install Debian base system, you need to boot on Linux !
Just enter in the Firmware and type something like that:

boot your_device zimage:chrp root=/dev/yourlinuxpartition

Replace your_device, by the device where is located zimage:chrp (eg ide0:0).
Replace /dev/yourlinuxpartition, by the partition where is located Linux (eg /dev/hda6).

3.4 Full installation


After a little while, Linux should start the final install process ! Be happy !
The purpose of this howto is no to describe the complete Debian installtion, therefore, this chapiter is no complete. However, there should be enough stuff to help beginner a lot! Please see the official Debian installatin guide for more help.

First screen: It congratulates you, just press OK.
Second screen: Read it if you want! Press OK

Keymaps: You just have to select the keymaps you want to use. Example: French people choose use pc/azerty latin0

Hardware clock: NO ! (I don't know why, but everybody advises me that.)

Time zone: Now, the Debian installer ask you for your time zone. Just do it !

MD5: Select YES. It will enable to encrypt the password.

Shadow password: YES. The password are saved in /etc/shadow instead of /etc/passwd.

Root password: The root is the super-user, it means he can do everything he wants! Select this password carefully and do not forget it. If someone nasty knows your root password, he can take the control of your computer if you are connected to a network!

Normal user: Now, you should create some user accounts. Linux is a multi-user operating system. It means that every user has his own space, his own configuration ... You may at least create one user (you !), and maybe others (for anyone that will use your computer).

Remove PCMCIA: YES. There is no PCMCIA on Pegasos, so let's remove it.

PPP Connection: Just answer NO: You can configure it easily with kpppd later

CD Scan: Now the installer will scan all your Debian CD to discover which packages you can install.

Another APT Source: Select NO. If you have a fast Internet connection, you will be able to install update and packages directly from the debian mirror. However, you will do it later in tips.

Security update: Select YES if you have a working Internet connection. If you are unsure choose NO.
Tasksel: Tasksel enables to select many packages with a few options. I advise you to select:
Dselect: Like Tasksel but harder to use. Just select NO if you are not an expert.

Now, the installer install and configure the whole system. You should be patient...

3.5 How to install lastest XFree


Why should I install the lastest XFree86?
First, it is always better to have lastest stable version of something than to use an old one. The lastest can be faster, nicer, more stable ...
Moreover, some Radeon have problem with XFree 4.1.x (The version installed by the Debian). For example, I can only use the 8 bits screens, because 15,16 or 24 bits screens are corrupted (bad color or yellow only). And, XF 4.2.1 support Radeon 3D acceleration (as soon as the kernel will be ready for that).

Where should I get lastest version of XFree86?
You had to get the source, because there are no binaries for XFree86 on PowerPC.
Go on http://www.xfree86.organd download the lastest sources.
Usually, you should download 4 files into a Linux partition:
Explanation: the Xfree86 team gives full source for each "major" update like V4.1.0, V4.2.0, but for little update (V4.2.1 ...) only the "patch" is released.
Therefore, you need to download the lastest full sources (current is 4.2.0) and the patch (4.2.1).

The installation
A) Compile and install from the sources

Be sure you are root.
First, install some packages needed to compile XFree:
Unpack the archive: tar -xzvf X420-src1.tgz (do the same for the two others file). It should create a directory named "xc"
and the patch tar -xzvf 4.2.0-4.2.1.diff.gz
Patch the sources:
Compile XFree ! In the xc directory
>make World && make install

It will take a lot of times ! Probably many hours ! Be patient !

Once this task is finished with success, you should have the lastest XFree86! Congratulations !

B) Use Apt-get (for fast internet connection only)
We will use apt-get to install XFree easily. I fact, lastest version is available but in "unstable". "Unstable" are the most recent packages but they are not yet tested to be named "stable". So we will ask apt-get to upgrade our system to "unstable" to get lastest Xfree (do not worry unstable with Debian is not unstable !).

Thanks to Peter Kaltstein for this tips
Nevertheless, I have no tested that,and using "unstable" Debian might be funny ... I advise you to compile the sources


4) Tips



Some tips about Linux:


5) FAQ



What about the Thendic Debian/Linux bootable CD ?
I do not have this CD currently, so I can not tell you more about that. As soon as I can get it, this howto will be updated ! However, this CD should enable to boot without floppy disk, so just skip "2.1 Create a boot disk" and "3.1 First boot".

Is it possible to use the MacOS on the top of Linux ?
Yes it is ! You have to use MOL (MacOnLinux).

I have problem using IDE devices connected on the second port. Is it normal ?
Well no ! But it is a known problem. It might be fix with a new kernel or/and bugless Pegasos (Pegasos with April).

Linux is damn slow compared to MorphOS! How is it possible ?
Linux is a dramatically different OS from MorphOS! It is a UNIX that manages many many services for network-oriented applications (like Apache, FTP server, SSH server ...). Moreother, Linux memory management is more complicated because it has to take care of user space and so on... All of that use CPU, but a lot of memory! In conclusion, you may buy some memory, especially if you only have 128 MB, to get a faster Linux. In my own opinion, Linux can not be as fast as MorphOS because it is far better design (for speed), Linux -> Wonderful for network-oriented application, MorphOS -> Wonderful :-) (but not for multi-user purpose).

The installer ask me XXXX, There is no mentioned of that in your howto!
Well, this howto is certainly not perfect. If you have problem do not hesitate to contact me. I will try to help you and then update this lovely howto :-). My email: det.nicolas@free.fr

How can I mount an Amiga partition ?
First, only FFS partition are supported. The command is simple, in root type ">mount /dev/xxxx /mnt/myamigapartitin -t affs". You can add a line in /etc/fstab to mount the Amiga partition at each startup:
/dev/xxxx /mnt/myamigaparitoopn affs user,noauto 0 0

6) Links



Some Linux PPC/Pegasos links: