User Tools

Site Tools


docs:man:installing_pld_linux_based_on_rescue_cd

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
docs:man:installing_pld_linux_based_on_rescue_cd [2008-12-08 12:45]
grizz rpm --root /pld --initdb
docs:man:installing_pld_linux_based_on_rescue_cd [2019-01-21 20:21] (current)
arekm [Kernel installation]
Line 9: Line 9:
  
 ===== Requirements ===== ===== Requirements =====
-Download RescueCD from : [[http://rescuecd.pld-linux.org/​|http://​rescuecd.pld-linux.org/​]] You need at least a i486 machine with 40MB RAM to run PLD RescueCD +Download RescueCD from : [[docs:rescuecd|Rescue CD]]PLD rescue new is preferred.
  
  
 ===== Partition disk ===== ===== Partition disk =====
-Use for example ''​cfdisk''​ to partition your destination disk. Usually root partition (/) and swap is enough. ​\\ :!: Write something more here :!: +Use for example ''​cfdisk''​ to partition your destination disk. Usually root partition (/) and swap is enough.
  
 +\\ :!: Write something more here :!: 
  
  
-===== Filesystem ===== 
-Initiate swap space  
  
 +===== Filesystem =====
 +Initiate swap space:
 <​file>#​ mkswap /dev/sda1 <​file>#​ mkswap /dev/sda1
 </​file>​ </​file>​
-Make filesystem (ex. ext3)  
  
-<​file>#​ mkfs.ext3 /dev/sda2+Make filesystem (ex. ext4):  
 +<​file>#​ mkfs.ext4 /dev/sda2
 </​file>​ </​file>​
-We need to create mountpoint, and mounnt partition into it.  
  
 +We need to create mountpoint and mount partition into it:
 <​file>#​ mkdir /pld <​file>#​ mkdir /pld
-# mount /dev/hda2 /pld+# mount /dev/sda2 /pld
 </​file>​ </​file>​
-If We want to use more partitions (ex. /boot), We need to mount it too.  
  
 +If more partitions are going to be used (like you want to have separate /boot or /home) then these need to be mounted now, too.
 +===== Network configuration of RescueCD =====
  
 +RescueCD and installed PLD system will use the same way of configuring network.
  
-===== Network configuration ===== +By default both try to use DHCP to automatically ​configure network interface ​during a boot process. 
-''​RescueCd''​ should configure (using ​DHCP) our network ​automatically during a boot process. If DHCP is not present, We need to do it manuallyLet's assume We want to set IP to 192.168.0.2. **/​etc/​sysconfig/​interfaces/​ifcfg-eth0** should looks like: +If that works for you you don'​t ​need to do anything. 
 + 
 +If manual configuration is required then configure networking using files below. 
 + 
 +==== eth0 interface configuration: ​/​etc/​sysconfig/​interfaces/​ifcfg-eth0 ​==== 
 + 
 +Assume you want 192.168.0.2 with /24 network (CIRD notation is preferred)
  
 <​file>​DEVICE=eth0 <​file>​DEVICE=eth0
-IPADDR=192.168.0.2+IPADDR=192.168.0.2/24
 ONBOOT=yes ONBOOT=yes
 BOOTPROTO=none BOOTPROTO=none
 </​file>​ </​file>​
-In file **/​etc/​sysconfig/​static-routes** ​ We added route to gateway (ex.: 10.0.0.254): ​ 
  
-<​file>​eth0 ​default ​via 10.0.0.254 +==== Default gateway and default ​gateway interface configuration: ​/etc/sysconfig/​network ====
-</​file>​ +
-In file **/etc/resolv.conf** we add at least one adress of DNS server: ​+
  
-<​file>​nameserver 193.192.160.243 +enable networking, ipv4 networking, set default gateway and interface which should be used to reach geteway:
-</​file>​ +
-In the end We need to reload network configuration+
  
-<​file>​# service network restart+<​file>​ 
 +NETWORKING=yes 
 +IPV4_NETWORKING=yes 
 +GATEWAY=192.168.0.254 
 +GATEWAYDEV=eth0
 </​file>​ </​file>​
 +
 +==== DNS resolver IP addresses configuration:​ /​etc/​resolv.conf ====
 +
 +Add default nameservers:​
 +
 +<​file>​nameserver 1.1.1.1
 +nameserver 8.8.8.8</​file>​
 +
 +=== Reload network ===
 +
 +<​file>#​ service network restart</​file>​
  
  
Line 69: Line 87:
 ===== Packages installation ===== ===== Packages installation =====
  
 +All packages are installed using **poldek** tool (it is a package manager for PLD).
  
 <​file>#​ rpm --root /pld --initdb <​file>#​ rpm --root /pld --initdb
 # poldek --root /pld # poldek --root /pld
  
-poldek> install ​setup FHS dev pwdutils chkconfig dhcpcd poldek vim geninitrd \ +poldek> install ​LIST OF PACKAGES REQUIRED FOR RUNNING SYSTEM
-modutils cpio lilo mount login mingetty+
 </​file>​ </​file>​
 +
 +Packages which make sense to be installed:
 +
 +<​file>​udev pwdutils dhcpcd poldek vim geninitrd grub2 e2fsprogs tzdata glibc-localedb-all</​file>​
 +
 +If **xfs** filesystem was chosen then please install:
 +
 +<​file>​xfsprogs</​file>​
 +
 +
 \\ :!: Write something more here :!:  \\ :!: Write something more here :!: 
  
Line 85: Line 113:
 ==== Prepare to install kernel ==== ==== Prepare to install kernel ====
  
 +Before installing kernel you need to mount kernel proc, sys and dev filesystems inside of chroot:
  
-<​file>#​ mount /proc /pldroot/proc -o bind+<​file>#​ mount -o bind /proc /pld/proc 
 +# mount -o bind /sys /pld/sys 
 +# mount -o bind /dev /pld/dev
 </​file>​ </​file>​
-Configure **/​etc/​fstab** ex.: + 
 +You need to tell initrd generator which hardware driver is needed to access your rootfs filesystem 
 +by setting scsi_hostadapter alias in **/​etc/​modprobe,​d/​modprobe.conf** (or any other file in that directory) 
 + 
 +<​file>​alias scsi_hostadapter ahci</​file>​ 
 + 
 +**lspci -k** command run on rescuecd can help you to find a correct driver: 
 + 
 +<​file>​ 
 +00:01.1 IDE interface: Intel Corporation 82371AB/​EB/​MB PIIX4 IDE (rev 01) 
 +        Kernel driver in use: ata_piix 
 +        Kernel modules: ata_piix, pata_acpi, ata_generic 
 +</​file>​ 
 + 
 +Note **Kernel driver in use: ata_piix** (alias scsi_hostadapter ata_piix) 
 + 
 +While at it, on actual installed PLD system (not needed on rescuecd), you can do the same for network card driver: 
 + 
 +<​file>​alias netdev-eth0 e1000e</​file>​ 
 + 
 +(again **lspci -k** will help to choose correct one) 
 + 
 + 
 +Configure **/pld/​etc/​fstab** ex.: 
  
 <​file>/​dev/​sda1 swap swap defaults 0 0 <​file>/​dev/​sda1 swap swap defaults 0 0
-/dev/sda2 /    ​ext3 defaults 0 0+/dev/sda2 /    ​ext4 defaults 0 0
 </​file>​ </​file>​
 +
 \\ :!: Write something more here :!:  \\ :!: Write something more here :!: 
  
Line 100: Line 155:
  
  
-<​file>#​ poldek --root /pld -i kernel +<​file>#​ poldek --root /pld -i kernel</​file>​ 
-</​file>​+ 
 +or 
 + 
 +<​file>#​poldek --root /pld -i kernel-some-specific-version</​file>​ 
 + 
 +You can also install multiple different kernels. 
 + 
 +By default kernel installation also generates initrd based on mounted /proc, /sys, /dev files and configured fstab, modprobe.conf and few others configuration files. generated initrd (which by default is initramfs cpio image) is saved in /boot. 
 + 
 +---- 
 + 
 +There are two initrd generators used in PLD: geninitrd and dracut. Choose one. 
 + 
 +=== geninitrd === 
 + 
 +If something fails or you want to regenerate initrd manually you can do it using: 
 + 
 +<​file>/​sbin/​geninitrd -v -f /​boot/​initd-XXX-Y.gz XXX-Y</​file>​ 
 + 
 +command. Real example: 
 + 
 +<​file>/​sbin/​geninitrd -v -f /​boot/​initd-4.20.3-1.gz 4.20.3-1</​file>​ 
 + 
 +//-v// option causes geninitrd to write additional information,​ so you can see if proper kernel modules are being installed into initrd. 
 + 
 +=== dracut === 
 + 
 +:!: Write something more here :!: 
 + 
 +---- 
 + 
 +PLD supports systemd and non-systemd installations. In case of systemd installation you need to install package 
 + 
 +<​file>​systemd</​file>​ 
 + 
 +package and setup default boot kernel cmdline option in grub/lilo. Add 
 + 
 +<​file>​init=/​bin/​systemd systemd.unit=graphical.target</​file>​
  
  
 +If booting with new initrd fails you can use **debuginitrd** and **debuginitrd=sh** boot kernel cmdline options to debug the problem.
 ===== Bootloader ===== ===== Bootloader =====
  
 +==== grub2 ====
  
-==== lilo ==== +Install grub2 on boot sector of disk: 
-Edit **/​etc/​lilo.conf** ​+ 
 +<​file>​grub-install /​dev/​sda</​file>​ 
 + 
 +Generate configuration file for grub2: 
 + 
 +<​file>​update-grub</​file>​ 
 + 
 +Resulting file is saved as **/​boot/​grub/​grub.cfg**. Setting custom options for grub2 can be done in **/​etc/​sysconfig/​grub** (then regenerate **grub.cfg** with **update-grub** command). 
 + 
 + 
 +==== lilo (deprecated) ​==== 
 +Edit **/pld/​etc/​lilo.conf** ​
  
 <​file>​boot=/​dev/​sda <​file>​boot=/​dev/​sda
Line 126: Line 231:
 </​file>​ </​file>​
  
 +==== Advanced configuration ====
 +Advanced lilo and grub configuration is described here: [[:​Docs:​man:​Bootloader|../​Bootloader]] ​
  
-==== grub ==== 
-Edit **/​boot/​grub/​menu.lst** ​ 
  
  
 +===== udev =====
 +\\ :!: Write something more here :!: 
  
-<​file>​timeout 10 
  
-title  pld 
-root (hd0,1) 
-kernel /​boot/​vmlinuz boot=/​dev/​hda 
-initrd /​boot/​initrd 
-</​file>​ 
-And execute ​ 
  
-<​file>#​ chroot /pld /​sbin/​grub +===== User accounts =====
-</​file>​ +
-A Grub's shell will started. Let's make some changes: ​+
  
-<​file>​grub> ​root (hd0,1) +By default **root** account doesn'​t have any password set and by default that will prevent you from logging in. Setup root password
-grub> setup (hd0) +
-grub> quit +
-</​file>​+
  
 +<​file>​chroot /pld && passwd</​file>​
  
-==== Advanced configuration ==== +\\ :!Write something more here :!
-Advanced lilo and grub configuration is described here[[:Docs:man:Bootloader|../​Bootloader]] ​+
  
 +===== Finishing =====
  
 +If manual network configuration was required for RescueCD then most liikely you need to repeat that [[docs:​man:​installing_pld_linux_based_on_rescue_cd#​network_configuration_of_rescuecd|step]] on installed PLD system, too.
  
-===== udev ===== +Last step is umount all filesystems:
-\\ :!: Write something more here :!+
  
 +<​file>​umount -R /​pld</​file>​
  
 +and reboot:
  
-===== User accounts ===== +<​file>​reboot</​file>​. 
-\\ :!: Write something more here :!: + 
 + 
 +If you find errors on this page or want to add anything to installation procedure please write to us at feedback / pld-linux.org.
  
-===== Finishing ===== 
 \\ :!: Write something more here :!:  \\ :!: Write something more here :!: 
  
docs/man/installing_pld_linux_based_on_rescue_cd.1228736708.txt.gz · Last modified: 2008-12-08 12:45 by grizz