Targetting other file systems besides iso
by John (J5) Palmieri
At OLPC we need to support ext3 and jffs2 builds even more so than
livecd isos. Since most of the process is the same up until the final
image and bootloaders we would like to add this support into the livecd
tools so that all fedora projects use one toolchain. The question is
how can this best be accomplished?
I think passing a --variant switch (i.e. --variant=jffs2) should switch
the backend to generating the correct image. This also requires
template support and the ability to select templates to write out based
on the variant in the %post. For instance the olpc.fth file is read in
by the openfirmware. For jffs2 builds we point to the nand on the XO
machines. For ext3 we point to a USB disk. Also on ext3 we write out
grub entries for use with standard machines and vitalization software
like qemu.
What would be the best way to add this support to the livecd tools?
--
John (J5) Palmieri <johnp(a)redhat.com>
16 years, 4 months
Support for custom configuration using python templates
by John (J5) Palmieri
This is the first in a bunch of OLPC needs I will be writing about on
the list. It is super simple for me to hack up solutions that work for
us but I would like to find a common solution that benefits all Fedora
based projects.
One of the things we need to for OLPC from the LiveCD creator is the
ability to output configuration files from a template. We do this
currently in Pilgrim and can do this in the LiveCD tools via the %post
as shell scripts. This is pretty unwieldy and tends to be error prone
with typos and missing character escapes causing sometimes hard to debug
problems.
A simple idea is to have standard template mechanism such as using
pythons string substitutions. For example take the file /etc/issue. In
shell we do this:
cat <<EOF > $INSTALL_ROOT/etc/issue
OLPC build $BUILD (stream $STREAM; variant $VARIANT)
Kernel \r on an \m
EOF
It would be nice to have a template file which read something like:
OLPC build %(build) (stream %(stream); variant %(variant))
Kernel \r on an \m
and simply passed in a hash with substitutions from the livecd tools.
Python templates or whatever templates is not really the issue here.
What is the issue is defining a standard template format to use,
defining how the tool finds the templates and defining how substitutions
are specified.
Any suggestions? I am willing to do the code myself but in the lack of
any interest I'm going to end up creating a one off solution, so mucho
input is desired.
--
John (J5) Palmieri <johnp(a)redhat.com>
16 years, 4 months
Intenet access with LiveCD?
by Jim Dever
Hi,
I was excited to see the release of the Fedora LiveCD as I'm looking
around at different distributions but for some reason I can't get it to
see my internet connection at all.
If anyone could point me in the right direction I'd appreciate it.
NIC: Cnet PRO200WL PCI (not wireless)
Router: Linksys RTP300
Output of ifconfig:
eth0 Link encap:Ethernet HWaddr 00:80:AD:79:95:90
inet addr: 192.168.15.102 Bcast: 192.168.15.255 Mask: 255.255.255.0
inet6 addr: fe80::280:adiff:fe79:9590/64 Scope: Link
UP BROADCAST MULTICAST MTU:1500 Metric: 1
RX packets: 13 errors: 170 dropped: 0 overruns: 0 frame: 0
TX packets: 0 errors: 10 dropped: 0 overruns: 0 carrier: 10
collisions: 0 txqueuelen: 1000
RX bytes: 2597 (2.5 KiB) TX bytes: 0 (0.0 b)
Interrupt: 201 Base address: 0xec00
-----
I noticed that it says UP but not RUNNING.
The Ubuntu LiveCD access the internet just fine so I know it's possible
to MAKE it work. I just like to see it work before making room for a
full install.
I've used Linux before but it's been ages ago and before I had a NIC so
I'm pretty new to this part.
Any help would be appreciated!
--
Jim
16 years, 5 months
Re: [Fedora-livecd-list] Installation of Fedora 7 Test 4 F-6.93 Gnome CD
by Antonio Olivares
----- Original Message ----
From: Antonio Olivares <olivares14031(a)yahoo.com>
To: For testers of Fedora Core development releases <fedora-test-list(a)redhat.com>
Sent: Monday, April 30, 2007 1:41:04 PM
Subject: Re: [Fedora-livecd-list] Installation of Fedora 7 Test 4 F-6.93 Gnome CD
--- Jeremy Katz <katzj(a)redhat.com> wrote:
> On Mon, 2007-04-30 at 07:33 -0700, Antonio Olivares
> wrote:
> > I have installed F-6.93 Fedora 7 Test 4 onto a
> > Toshiba laptop via LiveCD. Everything worked
> > beautifully. Upon rebooting, things were looking
> okay
> > until I saw the following:
>
> What type of partitioning did you do for the
> install?
I had previously shrunk the NTFS partition to allow me
to install fedora. I had created a swap space before.
I used the option "keep all linux partions and create
default layout".
root@darkstar:~# fdisk -l
Disk /dev/sda: 120.0 GB, 120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id
System
/dev/sda1 1 192 1536000 27
Unknown
Partition 1 does not end on cylinder boundary.
/dev/sda2 * 193 10113 79690432+ 7
HPFS/NTFS
/dev/sda3 10114 10375 2097152+ 82
Linux swap
/dev/sda4 10376 14593 33881085 5
Extended
/dev/sda5 10376 10388 104391 83
Linux
/dev/sda6 10389 14593 33776631 8e
Linux LVM
root@darkstar:~#
>
> > Looks like something did not go well while it
> appeared
> > everything did. I should first check with a
> rescue cd
> > or install dvd to see that it finds valid
> filesystem
> > and then report back.
>
> Yeah, that would be a good first step. If it does,
> grab the initrd and
> attach it to a bug against mkinitrd
I booted into rescue mode and everything seems
correct. The image is there.
root@darkstar:~# ls /mnt/sda5/
System.map-2.6.20-1.3104.fc7
initrd-2.6.20-1.3104.fc7.img
config-2.6.20-1.3104.fc7 lost+found/
grub/
vmlinuz-2.6.20-1.3104.fc7
root@darkstar:~# ls /mnt/sda5/ -l
total 5771
-rw-r--r-- 1 root root 929390 Apr 22 02:34
System.map-2.6.20-1.3104.fc7
-rw-r--r-- 1 root root 75847 Apr 22 02:34
config-2.6.20-1.3104.fc7
drwxr-xr-x 2 root root 1024 Apr 30 2007 grub/
-rw------- 1 root root 2902181 Apr 30 2007
initrd-2.6.20-1.3104.fc7.img
drwx------ 2 root root 12288 Apr 30 12:41
lost+found/
-rw-r--r-- 1 root root 1951092 Apr 22 02:34
vmlinuz-2.6.20-1.3104.fc7
root@darkstar:~#
root@darkstar:~# cat /mnt/sda5/grub/grub.conf
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making
changes to this file
# NOTICE: You have a /boot partition. This means
that
# all kernel and initrd paths are relative to
/boot/, eg.
# root (hd0,4)
# kernel /vmlinuz-version ro
root=/dev/VolGroup00/LogVol00
# initrd /initrd-version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,4)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.20-1.3104.fc7)
root (hd0,4)
kernel /vmlinuz-2.6.20-1.3104.fc7 ro
root=LABEL=/ rhgb quiet
initrd /initrd-2.6.20-1.3104.fc7.img
title Other
rootnoverify (hd0,1)
chainloader +1
>
> Jeremy
>
> --
> fedora-test-list mailing list
> fedora-test-list(a)redhat.com
> To unsubscribe:
>
https://www.redhat.com/mailman/listinfo/fedora-test-list
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
--
fedora-test-list mailing list
fedora-test-list(a)redhat.com
To unsubscribe:
https://www.redhat.com/mailman/listinfo/fedora-test-list
Replying to myself, but for the archives
I retried again. This time removing all the linux partitions and installation worked!!! Cannot complain running F7 T4 on Toshiba Laptop.
Thanks,
Antonio
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
16 years, 5 months
PowerPC support.
by David Woodhouse
At http://git.infradead.org/?p=users/dwmw2/livecd-ppc.git
(git://git.infradead.org/~dwmw2/livecd-ppc.git) there's a set of patches
which first introduces a little abstraction for the arch-specific
configureBootloader() and createIso() functions, then implements the PPC
version.
1. Allow mayflower path to be specified, to run from git tree
2, Remove syslinux from package lists; add it dynamically instead.
3. Move x86-specific functions (createIso, configureBootloader) into subclass
4. Only create isolinux/ directory in x86-specific configureBootloader()
5. Add PowerPC support, add pata_mpc52xx module to mayflower.conf
The full patch is as follows...
diff --git a/config/livecd-fedora-desktop.ks b/config/livecd-fedora-desktop.ks
index 1ee6fba..780e201 100644
--- a/config/livecd-fedora-desktop.ks
+++ b/config/livecd-fedora-desktop.ks
@@ -23,7 +23,6 @@ services --enabled=NetworkManager,dhcdbd --disabled=network,sshd
@dial-up
@hardware-support
@printing
-syslinux
kernel
scim*
diff --git a/config/livecd-fedora-kde.ks b/config/livecd-fedora-kde.ks
index 20413b1..9aeceed 100644
--- a/config/livecd-fedora-kde.ks
+++ b/config/livecd-fedora-kde.ks
@@ -23,7 +23,6 @@ kernel
dejavu-lgc-fonts
setroubleshoot
smolt
-syslinux
system-config-display
xorg-x11-drivers
diff --git a/config/livecd-fedora-minimal.ks b/config/livecd-fedora-minimal.ks
index e8065b6..db52912 100644
--- a/config/livecd-fedora-minimal.ks
+++ b/config/livecd-fedora-minimal.ks
@@ -17,7 +17,6 @@ repo --name=a-extras-dev --baseurl=http://download.fedora.redhat.com/pub/fedora/
%packages
bash
kernel
-syslinux
passwd
policycoreutils
chkconfig
diff --git a/config/livedvd-fedora-kde.ks b/config/livedvd-fedora-kde.ks
index 1ed2f57..71aa122 100644
--- a/config/livedvd-fedora-kde.ks
+++ b/config/livedvd-fedora-kde.ks
@@ -23,7 +23,6 @@ kernel
dejavu-lgc-fonts
setroubleshoot
smolt
-syslinux
system-config-display
xorg-x11-drivers
diff --git a/creator/livecd-creator b/creator/livecd-creator
index a526b07..755e659 100755
--- a/creator/livecd-creator
+++ b/creator/livecd-creator
@@ -27,6 +27,8 @@ import traceback
import subprocess
import shutil
import yum
+import rpmUtils.arch
+import rhpl
import pykickstart.parser
import pykickstart.version
@@ -277,6 +279,178 @@ class LiveCDYum(yum.YumBase):
cb.filelog = False
return self.runTransaction(cb)
+class InstallationArchPPC:
+ def __init__(self):
+ # For now we need anaconda-runtime, for bits like ofboot.b and mapping files.
+ # We could generate those ourselves though...
+ self.bootldr_package = ("yaboot","anaconda-runtime")
+
+ def createIso(self, target):
+ """write out the live CD ISO"""
+ subprocess.call(["/usr/bin/mkisofs", "-o", "%s.iso" %(target.fs_label,),
+ "-hfs", "-hfs-bless", "%s/out/ppc/mac" %(target.build_dir),
+ "-hfs-volid", "%s" %(target.fs_label,), "-part",
+ "-map", "/usr/lib/anaconda-runtime/boot/mapping",
+ "-J", "-r", "-hide-rr-moved", "-no-desktop",
+ "-V", "%s" %(target.fs_label,), "%s/out" %(target.build_dir)])
+
+ def configureBootloader(self, target):
+ """configure the boot loader"""
+
+ # Copy yaboot and ofboot.b in to mac directory
+ os.makedirs(target.build_dir + "/out/ppc/mac")
+ shutil.copyfile("%s/install_root/usr/lib/anaconda-runtime/boot/ofboot.b" %(target.build_dir),
+ "%s/out/ppc/mac/ofboot.b" %(target.build_dir,))
+ shutil.copyfile("%s/install_root/usr/lib/yaboot/yaboot" %(target.build_dir),
+ "%s/out/ppc/mac/yaboot" %(target.build_dir,))
+
+ # Copy yaboot and ofboot.b in to mac directory
+ os.makedirs(target.build_dir + "/out/ppc/chrp")
+ shutil.copyfile("%s/install_root/usr/lib/anaconda-runtime/boot/bootinfo.txt" %(target.build_dir),
+ "%s/out/ppc/bootinfo.txt" %(target.build_dir,))
+ shutil.copyfile("%s/install_root/usr/lib/yaboot/yaboot" %(target.build_dir),
+ "%s/out/ppc/chrp/yaboot" %(target.build_dir,))
+ subprocess.call(["/usr/sbin/addnote", "%s/out/ppc/chrp/yaboot" %(target.build_dir,)])
+
+ os.makedirs(target.build_dir + "/out/ppc/ppc32")
+ shutil.copyfile("%s/install_root/boot/vmlinuz-%s"
+ %(target.build_dir, target.get_kernel_version()),
+ "%s/out/ppc/ppc32/vmlinuz" %(target.build_dir,))
+ shutil.copyfile("%s/install_root/boot/livecd-initramfs.img"
+ %(target.build_dir,),
+ "%s/out/ppc/ppc32/initrd.img" %(target.build_dir,))
+ os.unlink("%s/install_root/boot/livecd-initramfs.img"
+ %(target.build_dir,))
+
+ os.makedirs(target.build_dir + "/out/ppc/ppc64")
+ # FIXME: Need 64-bit kernel and initrd
+
+ cfg32 = """
+init-message = "Welcome to the Fedora %(label)s LiveCD"
+timeout=6000
+
+""" %{"label": target.fs_label}
+
+ stanzas = [("linux", "Run from image", ""),
+ ("runfromram", "Run from RAM - requires 1 GiB+", "live_ram")]
+ if os.path.exists("%s/install_root/usr/lib/anaconda-runtime/checkisomd5" %(target.build_dir,)):
+ stanzas.append( ("check", "Verify and run from image", "check") )
+
+ for (short, long, extra) in stanzas:
+ cfg32 += """
+
+image=/ppc/ppc32/vmlinuz
+ label=%(short)s
+ initrd=/ppc/ppc32/initrd.img
+ read-only
+ append="ro quiet root=CDLABEL=%(label)s rootfstype=iso9660 %(extra)s"
+""" %{"label": target.fs_label,
+ "short": short, "long": long, "extra": extra}
+
+ cfgf = open("%s/out/ppc/ppc32/yaboot.conf" %(target.build_dir,), "w")
+ cfgf.write(cfg32)
+ cfgf.close()
+ os.makedirs(target.build_dir + "/out/etc")
+ cfgf = open("%s/out/etc/yaboot.conf" %(target.build_dir,), "w")
+ cfgf.write(cfg32)
+ cfgf.close()
+
+ # FIXME. Obviously
+ cfg64 = """
+init-message = "Sorry, this LiveCD only supports 32-bit hardware"
+"""
+ cfgf = open("%s/out/ppc/ppc64/yaboot.conf" %(target.build_dir,), "w")
+ cfgf.write(cfg64)
+ cfgf.close()
+
+ # TODO: enable external entitity to partipate in adding boot entries
+ # build 'netboot' images with kernel+initrd, like mk-images.ppc
+
+class InstallationArchX86:
+ def __init__(self):
+ self.bootldr_package = ("syslinux",)
+
+ def createIso(self, target):
+ """write out the live CD ISO"""
+ subprocess.call(["/usr/bin/mkisofs", "-o", "%s.iso" %(target.fs_label,),
+ "-b", "isolinux/isolinux.bin",
+ "-c", "isolinux/boot.cat",
+ "-no-emul-boot", "-boot-load-size", "4",
+ "-boot-info-table", "-J", "-r", "-hide-rr-moved",
+ "-V", "%s" %(target.fs_label,), "%s/out" %(target.build_dir)])
+
+ def configureBootloader(self, target):
+ """configure the boot loader"""
+
+ # set up boot loader
+ #
+ # TODO:
+ # - fix for archs not using grub
+ # - fix for non-i386
+ # - error handling
+ #
+ os.makedirs(target.build_dir + "/out/isolinux")
+
+ shutil.copyfile("%s/install_root/boot/vmlinuz-%s"
+ %(target.build_dir, target.get_kernel_version()),
+ "%s/out/isolinux/vmlinuz" %(target.build_dir,))
+
+ shutil.copyfile("%s/install_root/boot/livecd-initramfs.img"
+ %(target.build_dir,),
+ "%s/out/isolinux/initrd.img" %(target.build_dir,))
+ os.unlink("%s/install_root/boot/livecd-initramfs.img"
+ %(target.build_dir,))
+
+ for p in ["isolinux.bin", "vesamenu.c32"]:
+ path = "%s/install_root/usr/lib/syslinux/%s" % (target.build_dir, p)
+
+ if not os.path.isfile(path):
+ raise InstallationError("syslinux not installed : %s not found" % path)
+
+ shutil.copy(path, "%s/out/isolinux/%s" % (target.build_dir, p))
+
+ if os.path.exists("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg" %(target.build_dir,)):
+ shutil.copy("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg" %(target.build_dir,),
+ "%s/out/isolinux/splash.jpg" %(target.build_dir,))
+ have_background = "menu background splash.jpg"
+ else:
+ have_background = ""
+
+ cfg = """
+default vesamenu.c32
+timeout 600
+
+%(background)s
+menu title Welcome to %(label)s!
+menu color border 0 #ffffffff #00000000
+menu color sel 0 #ffffffff #ff000000
+menu color title 0 #ffffffff #00000000
+menu color tabmsg 0 #ffffffff #00000000
+menu color unsel 0 #ffffffff #00000000
+menu color hotsel 0 #ff000000 #ffffffff
+menu color hotkey 0 #ffffffff #ff000000
+""" %{"label": target.fs_label, "background" : have_background}
+
+ stanzas = [("linux", "Run from image", ""),
+ ("runfromram", "Run from RAM - requires 1 GiB+", "live_ram")]
+ if os.path.exists("%s/install_root/usr/lib/anaconda-runtime/checkisomd5" %(target.build_dir,)):
+ stanzas.append( ("check", "Verify and run from image", "check") )
+
+ for (short, long, extra) in stanzas:
+ cfg += """label %(short)s
+ menu label %(long)s
+ kernel vmlinuz
+ append initrd=initrd.img ro quiet root=CDLABEL=%(label)s rootfstype=iso9660 liveimg %(extra)s
+""" %{"label": target.fs_label, "background" : have_background,
+ "short": short, "long": long, "extra": extra}
+
+ cfgf = open("%s/out/isolinux/isolinux.cfg" %(target.build_dir,), "w")
+ cfgf.write(cfg)
+ cfgf.close()
+
+ # TODO: enable external entitity to partipate in adding boot entries
+
+
class InstallationTarget:
def __init__(self, repos, packages, epackages, groups, fs_label, skip_compression, skip_prelink):
self.ayum = None
@@ -293,6 +467,14 @@ class InstallationTarget:
self.bindmounts = []
self.ksparser = None
+ myarch = rhpl.getArch()
+ if myarch == "i386" or myarch == "x86_64":
+ self.arch = InstallationArchX86()
+ elif myarch == "ppc":
+ self.arch = InstallationArchPPC()
+ else:
+ raise InstallationError("Do not know how to build LiveCD for arch '%s'" % (myarch,))
+
def parse(self, kscfg):
ksversion = pykickstart.version.makeVersion()
self.ksparser = pykickstart.parser.KickstartParser(ksversion)
@@ -377,7 +559,6 @@ class InstallationTarget:
except OSError, (err, msg):
raise InstallationError("Failed create build directory in /var/tmp: %s" % msg)
- os.makedirs(self.build_dir + "/out/isolinux")
os.makedirs(self.build_dir + "/out/sysroot")
os.makedirs(self.build_dir + "/data/sysroot")
os.makedirs(self.build_dir + "/install_root")
@@ -748,12 +929,12 @@ class InstallationTarget:
return kernels[0]
- def createInitramfs(self):
+ def createInitramfs(self, mayflower_path):
# Create initramfs
- if not os.path.isfile("/usr/lib/livecd-creator/mayflower"):
+ if not os.path.isfile(mayflower_path):
raise InstallationError("livecd-creator not correctly installed : "+
- "/usr/lib/livecd-creator/mayflower not found")
- shutil.copy("/usr/lib/livecd-creator/mayflower",
+ mayflower_path+" not found")
+ shutil.copy(mayflower_path,
"%s/install_root/sbin/mayflower" %(self.build_dir,))
# modules needed for booting (this is butt ugly and we need to retrieve this from elsewhere, e.g. the kernel)
mayflowerconf = open(self.build_dir + "/install_root/etc/mayflower.conf", "w")
@@ -761,7 +942,7 @@ class InstallationTarget:
mayflowerconf.write('MODULES+="sata_mv sata_qstor sata_sis sata_uli "\n')
mayflowerconf.write('MODULES+="sata_nv sata_sil24 sata_svw sata_via "\n')
mayflowerconf.write('MODULES+="sata_promise sata_sil sata_sx4 sata_vsc "\n')
- mayflowerconf.write('MODULES+="ata_generic pata_ali pata_amd pata_artop pata_atiixp pata_cmd64x pata_cs5520 pata_cs5530 pata_cs5535 pata_cypress pata_efar pata_hpt366 pata_hpt37x pata_hpt3x2n pata_hpt3x3 pata_isapnp pata_it821x pata_jmicron pata_marvell pata_mpiix pata_netcell pata_ns87410 pata_oldpiix pata_optidma pata_opti pata_pcmcia pata_pdc2027x pata_pdc202xx_old pata_qdi pata_serverworks pata_sil680 pata_sis pata_sl82c105 pata_triflex pata_via pdc_adma "\n')
+ mayflowerconf.write('MODULES+="ata_generic pata_ali pata_amd pata_artop pata_atiixp pata_cmd64x pata_cs5520 pata_cs5530 pata_cs5535 pata_cypress pata_efar pata_hpt366 pata_hpt37x pata_hpt3x2n pata_hpt3x3 pata_isapnp pata_it821x pata_jmicron pata_marvell pata_mpiix pata_netcell pata_ns87410 pata_oldpiix pata_optidma pata_opti pata_pcmcia pata_pdc2027x pata_pdc202xx_old pata_qdi pata_serverworks pata_sil680 pata_sis pata_sl82c105 pata_triflex pata_via pdc_adma pata_mpc52xx "\n')
mayflowerconf.close()
subprocess.call(["/sbin/mayflower", "-f", "/boot/livecd-initramfs.img",
@@ -789,76 +970,8 @@ class InstallationTarget:
def launchShell(self):
subprocess.call(["/bin/bash"], preexec_fn=self.run_in_root)
- def configureBootloader(self):
- """configure the boot loader"""
-
- # set up boot loader
- #
- # TODO:
- # - fix for archs not using grub
- # - fix for non-i386
- # - error handling
- #
- shutil.copyfile("%s/install_root/boot/vmlinuz-%s"
- %(self.build_dir, self.get_kernel_version()),
- "%s/out/isolinux/vmlinuz" %(self.build_dir,))
-
- shutil.copyfile("%s/install_root/boot/livecd-initramfs.img"
- %(self.build_dir,),
- "%s/out/isolinux/initrd.img" %(self.build_dir,))
- os.unlink("%s/install_root/boot/livecd-initramfs.img"
- %(self.build_dir,))
-
- for p in ["isolinux.bin", "vesamenu.c32"]:
- path = "%s/install_root/usr/lib/syslinux/%s" % (self.build_dir, p)
-
- if not os.path.isfile(path):
- raise InstallationError("syslinux not installed : %s not found" % path)
-
- shutil.copy(path, "%s/out/isolinux/%s" % (self.build_dir, p))
-
- if os.path.exists("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg" %(self.build_dir,)):
- shutil.copy("%s/install_root/usr/lib/anaconda-runtime/syslinux-vesa-splash.jpg" %(self.build_dir,),
- "%s/out/isolinux/splash.jpg" %(self.build_dir,))
- have_background = "menu background splash.jpg"
- else:
- have_background = ""
-
- cfg = """
-default vesamenu.c32
-timeout 600
-
-%(background)s
-menu title Welcome to %(label)s!
-menu color border 0 #ffffffff #00000000
-menu color sel 0 #ffffffff #ff000000
-menu color title 0 #ffffffff #00000000
-menu color tabmsg 0 #ffffffff #00000000
-menu color unsel 0 #ffffffff #00000000
-menu color hotsel 0 #ff000000 #ffffffff
-menu color hotkey 0 #ffffffff #ff000000
-""" %{"label": self.fs_label, "background" : have_background}
-
- stanzas = [("linux", "Run from image", ""),
- ("runfromram", "Run from RAM - requires 1 GB+", "live_ram")]
- if os.path.exists("%s/install_root/usr/lib/anaconda-runtime/checkisomd5" %(self.build_dir,)):
- stanzas.append( ("check", "Verify and run from image", "check") )
-
- for (short, long, extra) in stanzas:
- cfg += """label %(short)s
- menu label %(long)s
- kernel vmlinuz
- append initrd=initrd.img ro quiet root=CDLABEL=%(label)s rootfstype=iso9660 liveimg %(extra)s
-""" %{"label": self.fs_label, "background" : have_background,
- "short": short, "long": long, "extra": extra}
-
- cfgf = open("%s/out/isolinux/isolinux.cfg" %(self.build_dir,), "w")
- cfgf.write(cfg)
- cfgf.close()
- # TODO: enable external entitity to partipate in adding boot entries
-
- def install(self):
+ def install(self, mayflower_path):
for (name, url) in self.repos:
self.ayum.addRepository(name, url)
@@ -868,24 +981,8 @@ menu color hotkey 0 #ffffffff #ff000000
self.relabelSystem()
if not self.skip_prelink:
self.prelinkSystem()
- self.createInitramfs()
- self.configureBootloader()
-
- def createIso(self):
- """write out the live CD ISO"""
- subprocess.call(["/usr/bin/mkisofs", "-o", "%s.iso" %(self.fs_label,),
- "-b", "isolinux/isolinux.bin",
- "-c", "isolinux/boot.cat",
- "-no-emul-boot", "-boot-load-size", "4",
- "-boot-info-table", "-J", "-r", "-hide-rr-moved",
- "-V", "%s" %(self.fs_label,), "%s/out" %(self.build_dir)])
-
- # implant an isomd5sum
- if os.path.exists("/usr/lib/anaconda-runtime/implantisomd5"):
- subprocess.call(["/usr/lib/anaconda-runtime/implantisomd5",
- "%s.iso" %(self.fs_label,)])
- else:
- print >> sys.stderr, "anaconda-runtime not installed; not setting up mediacheck"
+ self.createInitramfs(mayflower_path)
+ self.arch.configureBootloader(self)
def createSquashFS(self):
"""create compressed squashfs file system"""
@@ -901,7 +998,14 @@ menu color hotkey 0 #ffffffff #ff000000
def package(self):
self.createSquashFS()
- self.createIso()
+ self.arch.createIso(self)
+ # implant an isomd5sum
+ if os.path.exists("/usr/lib/anaconda-runtime/implantisomd5"):
+ subprocess.call(["/usr/lib/anaconda-runtime/implantisomd5",
+ "%s.iso" %(self.fs_label,)])
+ else:
+ print >> sys.stderr, "anaconda-runtime not installed; not setting up mediacheck"
+
def usage(out):
print >> out, """
@@ -911,9 +1015,9 @@ usage: livecd-creator [--help]
[--package=<p1>] [--package=<p2> ...]
[--exclude-package=<e1>] [--exclude-package=<e2> ...]
[--base-on=<path-to-iso-file>]
- [--fslabel=<label>]
+ [--fslabel=<label>] [--mayflower=<path-to-mayflower-script>]
[--skip-compression]
- [--uncompressed-size=<size-in-MB>]
+ [--uncompressed-size=<size-in-MiB>]
[--shell]
--help : Print usage and exit
@@ -923,9 +1027,10 @@ usage: livecd-creator [--help]
--exclude-package : Exclude this package
--base-on : Add packages to an existing live CD iso9660 image
--fslabel : File system label (default: livecd-YYYYMMDD-HHMI)
+ --mayflower : Path to mayflower script
--skip-compression : Don't compress the image
--prelink : Prelink the image
- --uncompressed-size : Size of uncompressed fs in MB (default: 4096)
+ --uncompressed-size : Size of uncompressed fs in MiB (default: 4096)
--shell : Start a shell in the chroot for post-configuration
Examples:
@@ -952,6 +1057,7 @@ class Options:
self.fs_label = "livecd-" + time.strftime("%Y%m%d-%H%M")
self.base_on = None
self.kscfg = None
+ self.mayflower_path = "/usr/lib/livecd-creator/mayflower"
self.skip_compression = False
self.skip_prelink = True
self.uncompressed_size = 4096
@@ -963,7 +1069,7 @@ def parse_options(args):
["help", "repo=", "base-on=", "package=",
"exclude-package=", "fslabel=", "config=",
"skip-compression", "uncompressed-size=",
- "shell", "no-prelink", "prelink"])
+ "mayflower=", "shell", "no-prelink", "prelink"])
except getopt.GetoptError, msg:
raise Usage(msg)
@@ -992,6 +1098,11 @@ def parse_options(args):
if not os.path.isfile(options.kscfg):
raise Usage("Kickstart config '%s' does not exist" % options.kscfg)
continue
+ if o in ("--mayflower"):
+ options.mayflower_path = a
+ if not os.path.isfile(options.mayflower_path):
+ raise Usage("Mayflower script '%s' does not exist" % options.mayflower_path)
+ continue
if o in ("-r", "--repo"):
(name, url) = a.split(",")
for (n, u) in options.repos:
@@ -1057,10 +1168,12 @@ def main():
try:
target.parse(options.kscfg)
+
+ target.packages.extend(target.arch.bootldr_package)
target.setup(options.uncompressed_size, options.base_on)
- target.install()
+ target.install(options.mayflower_path)
if options.give_shell:
print "Launching shell. Exit to continue."
--
dwmw2
16 years, 5 months
Installation of Fedora 7 Test 4 F-6.93 Gnome CD
by Antonio Olivares
Dear all,
I have installed F-6.93 Fedora 7 Test 4 onto a
Toshiba laptop via LiveCD. Everything worked
beautifully. Upon rebooting, things were looking okay
until I saw the following:
scsi: 1:0:0:0:0: CD-ROM HL-DT-ST DVDRAM GMA-4082N
dev-mapper: ioctl: 4.11.0-ioctl (2006-10-12)
initialised: dm-devel(a)redhat.com
mount: could not find filesystem '/dev/root'
setuproot: moving /dev/ failed: no such file or
directory
setuproot: error mounting /proc: no such file or
directory
setuproot: mounting /sys: no such file or directory
switchroot: mount failed: no such file or directory
Kernel panic - not syncing: Attempted to kill init!
Looks like something did not go well while it appeared
everything did. I should first check with a rescue cd
or install dvd to see that it finds valid filesystem
and then report back.
Regards,
Antonio
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
16 years, 5 months
LiveCD Failure - Can't Stat stage2_eltorito
by Paul Dubinsky
Howdy, Folks,
This is my first try at creating a LiveCD on a newly installed FC6_64
and I'm having a problem.
Using livecd-creator as in:
livecd-creator --repo=c6,file:///var/www/html/repo/core
--repo=lcd6,file:///root/base_packages
--package=fedora-livecd-gnome
--repo=e6,http://download.fedora.redhat.com/pub/fedora/linux/extras/6/i386
--fslabel=My-Fedora-LiveCD-1
I get a failed exit with the msg:
/usr/bin/mkisofs: Uh oh, I cant find the boot image
'boot/grub/stage2_eltorito' !
Earlier:
/sbin/setfiles: error while labeling files under
/var/named/chroot/var/run/dbus
/bin/cp: cannot stat
`/var/tmp/livecd-creator/build-tmp-oMLql/install_root/usr/share/grub/i386-redhat/stage2_eltorito':
No such file or directory
Any suggestions about where to look for the problem?
Thanks,
Paul
--
=============================================
"Disease can be cured. Dakar, however,
is an addiction. Addictions are for life."
=============================================
16 years, 5 months
Fedora 7 Test 4 GNOME based i386 Live CD report
by Rahul Sundaram
Hi
Just installed the F7 T4 GNOME based i386 live cd and here are some of
my observations after playing with it for a day.
* You do not need to accept the EULA anymore. It just has a pointer to
the wiki link instead of including the text.
* Smolt integration UI is good and works well. Noticed that it said it
would update the profile automatically on a monthly basis. My test
system profile is
http://smolt.fedoraproject.org/show?UUID=492900d9-5ee0-441c-9792-fc2ecc86...
* Look and feel is good. Flying high theme with Mist based icon set.
* Firefox and Evolution are the default panel applications but seem to
be using the old Blue Curve icons.
* Network manager (nm-applet) is enabled by default
* Blog, stock ticker, bittorrent and gparted applications installed by
default
* fast user switcher applet is on the panel by default and shows up on
the lock screen. too.
* Multiple locales and input methods available by default
* Abiword does not crash on startup anymore. gnumeric is also available
but we are missing a small presentation program to complete this sort of
mini office suite.
* Beagle is installed by default and replaces gnome-search-tool on the
UI like the previous release. Might be better to keep these entries
separate.
* gThumb and GIMP are available by default but not f-spot.
* Pigdin has replaced Gaim. Has new icons and a better interface.
* Wodim has replaced cdrecord. cdrecord is a symlink to wodim and works
as expected.
* New application, system-config-selinux is available under
administration. Looks pretty comprehensive. SELinux boolean
configuration has been removed from system-config-securitylevel and is
now available in this tool. Title says "system-config-selinux.py"
instead of just "system-config-selinux" which is a minor wart in the UI.
* Places and /home/<user> is filled by default folders for documents,
video etc. Might look less cluttered if those default folder were under
a common parent. /home/<user>/personal/<default folders> for example.
* Preferences menu is organized into multiple categories now. The
central control panel that GNOME includes is disabled by default
(upstream inherited) but can be enabled using alacarte. Menu editor is a
entry now in the preferences menu.
* Yum is faster. Pirut and Pup UI does not appear to hang anymore.
* About Fedora menu entry uses old wordings and says Fedora people
instead of Planet Fedora as we have agreed upon now for consistency.
* nautilus-open-terminal extension was not installed by default unlike
previous live cd releases.
* SCIM input icon doesnt show up on the system tray unlike the previous
test release. Default is showing on demand but setting it to show always
does not make it show up on the system tray.
* nautilus has crashed more than once during login including the
previous test releases with some vague bonobo error which I did not note
down. Anyone else seeing this?
* Turning on desktop effects immediately makes it crash Xorg
* shutdown entry showed up twice as first and last entries in the system
menu just once.
Rest later,
Rahul
16 years, 5 months
Inheritance
by John (J5) Palmieri
In the pilgrim tool it is fairly easy to inherit from "stream" files and
just expand a base image into a newer image. This means I can create a
base description for an image, with all the required rpms and %post
processing and then define another image description which adds more
rpms and does more post processing. We can even override hooks and
files in the child description. For instance our liveCD SDK has added
gnome packages but does not download the ondisk html library to save
space. This allows me to make changes to the base image which is
automatically reflected in the livecd image builds.
The real reason we need this is for country builds. I know that the
livecd tools already have the ability to take an iso and add to it but I
also need the ability to do a build from scratch. First can the current
kickstart file format handle this and second how can we support this if
it does not?
--
John (J5) Palmieri <johnp(a)redhat.com>
16 years, 5 months
Re: Learning why packages are getting installed
by Matthias Clasen
I forgot to mention that my program can also dump strong components (ie
dependency cycles). Here are the results:
ConsoleKit-libs <-> MAKEDEV <-> SysVinit <-> coreutils <-> dbus <->
device-mapper <-> device-mapper-libs <-> e2fsprogs <-> e2fsprogs-libs
<-> initscripts <-> krb5-libs <-> libselinux <-> libxml2-python <->
logrotate <-> mcstrans <-> module-init-tools <-> net-tools <-> openssl
<-> pam <-> psmisc <-> python <-> python-libs <-> shadow-utils <->
sysklogd <-> udev <-> util-linux
aspell <-> aspell-en
chkfontpath <-> xorg-x11-xfs
fast-user-switch-applet <-> gnome-panel
fedora-logos <-> redhat-artwork
festival <-> festvox-slt-arctic-hts
firstboot <-> system-config-keyboard
gnome-python2 <-> gnome-python2-bonobo <-> gnome-python2-gnomevfs
hal <-> hal-info
mono-web <-> mono-winforms
perl <-> perl-devel
rpm <-> rpm-libs
xorg-x11-drv-evdev <-> xorg-x11-drv-keyboard <-> xorg-x11-drv-mouse <->
xorg-x11-drv-vesa <-> xorg-x11-drv-void <-> xorg-x11-server-Xorg
yp-tools <-> ypbind
While most are small and easy to explain, there are a few horrible
ones, like the one involving ConsoleKit-libs
16 years, 5 months