Initiating minos-one
Ever wanted to try out Advanced Gtk+ Sequencer and Swami? Then you need minos-one download available at sourceforge.net:
This live DVD is shipped with most popular GNU software including:
- Advanced Gtk+ Sequencer
- Swami
- Mplayer
- ffmpeg
- …
It is a x86_64 build with realtime kernel linux-3.14.25-rt22. System requirements are probably lots of RAM. Me could borrow you with some anoying details but rather deciding to give you a brief howto extend minos-one Live DVD ….
Objectives
GNU/Linux is providing /dev/shm it is a tmpfs its advantages are all files are provided within RAM. Here comes the magic part. You builded a initrd kernel this initrd fs is provided in RAM as well and remounting root / is done anyway.
To get a full setup with source I would recommend you linuxfromscratch.org where you do /usr/share/mkinitramfs/init.in this is the file launched just before /sbin/init.
Note if you wish to start kernel command line:
linux vmlinuz initrd initrd.img init=/bin/bash
There’s a not documented /sbin/init paramater –init which does all magic ie. start init and invoke /etc/init.d
Setup directory structure and base files
First we create some directories to mount our ISO files:
$ cd /mnt
$ mkdir {image,rootfs,rootfs,usrfs,build,cdrom}
Create build.iso file which is large enough to contain and build linux kernel, here we create a 100G file for your builds so make sure to have enough disk space.
$ dd if=/dev/zero of=build.iso bs=512K count=200000
$ vfsnode=`losetup -f`
$ losetup -P $vfsnode build.iso
$ mkfs.ext4 $vfsnode
The created iso is now mounted using loopback device. To know what loopback device just enter:
$ echo $vfsnode
You can either do your own linux from scratch or do:
$ wget -c http://sourceforge.net/projects/ags/files/minos-lxdm.iso/download
$ mount -o loop minos-lxdm.iso /mnt/cdrom
For know we mount the rootfs and usr directory of our live DVD by issueing:
$ cp -rv cdrom/* image
$ mount -o loop image/casper/rootfs.iso rootfs
$ mount -o loop image/casper/usr.iso rootfs/usr
$ mount $vfsnode rootfs/sources
Chroot to the ISO environment
Chroot provides you a nested root environment further we bind devfs to the chroot environment.
$ mount -v --bind /dev rootfs/dev
$ mount -vt devpts devpts rootfs/dev/pts -o gid=5,mode=620
$ mount -vt proc proc rootfs/proc
$ mount -vt sysfs sysfs rootfs/sys
$ mount -vt tmpfs tmpfs rootfs/run
$ chroot /mnt/rootfs /usr/bin/env -i
HOME=/root TERM="$TERM" PS1='u:w$ '
PATH=/bin:/usr/bin:/sbin:/usr/sbin
/bin/bash --login
For now your able to build your applications for the iso within chroot environment it is
to use /sources for your build since it’s really large and will not be included in the iso.
ISOLINUX
Download syslinux either with your favourite repository or from syslinux.org and unmount your ISOs when not needed anymore. So you have to logout the chroot environment:
$ exit
$ cd /mnt
$ umount rootfs/{dev/pts,sys,proc,run,dev}
$ umount rootfs/{sources,usr,}
The build your ISO and burn it using cdrecord or wodim:
$ cd image
$ mkisofs -o ../minos-lxdm-new.iso
-b isolinux/isolinux.bin -c isolinux/boot.cat
-no-emul-boot -boot-load-size 4 -boot-info-table
.
$ cd .. && cdrecord -v minos-lxdm-new.iso