tools/livecd-iso-to-disk.sh
by Jeremy Katz
tools/livecd-iso-to-disk.sh | 57 ++++++++++++++++----------------------------
1 file changed, 22 insertions(+), 35 deletions(-)
New commits:
commit 9b779482c390b399cb4a8e7c656982a39b974461
Author: Jeremy Katz <katzj(a)redhat.com>
Date: Fri Oct 3 19:55:32 2008 -0400
Auto-determine USB vs SD on the XO
Rather than requiring specifying whether you're doing USB or SD, we can
see which the fth script is actually running from. Do some magic
(again, thanks to Mitch Bradley) to do so
diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
index 5c20640..f385dcb 100755
--- a/tools/livecd-iso-to-disk.sh
+++ b/tools/livecd-iso-to-disk.sh
@@ -258,14 +258,6 @@ while [ $# -gt 2 ]; do
--xo)
xo=1
;;
- --xo-sd)
- xo=1
- xosd=1
- ;;
- --xo-usb)
- xo=1
- xousb=1
- ;;
--xo-no-home)
xonohome=1
;;
@@ -497,12 +489,13 @@ fi
# we'd do this unconditionally, but you have to have a kernel that will
# boot on the XO anyway.
if [ -n "$xo" ]; then
- echo "Setting up /olpc-usb.fth file"
+ echo "Setting up /boot/olpc.fth file"
args=$(egrep "^[ ]*append" $USBMNT/$SYSLINUXPATH/isolinux.cfg |head -n1 |sed -e 's/.*initrd=[^ ]*//')
if [ -n "$xonohome" -a ! -f $USBMNT/LiveOS/$HOMEFILE ]; then
args="$args persistenthome=mtd0"
fi
- cat > $USBMNT/olpc-usb.fth <<EOF
+ if [ ! -d $USBMNT/boot ]; then mkdir -p $USBMNT/boot ; fi
+ cat > $USBMNT/boot/olpc.fth <<EOF
\ Boot script for USB boot
patch 2drop erase claim-params
: high-ramdisk ( -- )
@@ -513,37 +506,31 @@ patch 2drop erase claim-params
;
' high-ramdisk to load-ramdisk
-" $args" to boot-file
-" u:\syslinux\initrd0.img" to ramdisk
-unfreeze
-boot u:\syslinux\vmlinuz0
-EOF
-
- echo "Setting up /olpc-sd.fth file"
- cat > $USBMNT/olpc-sd.fth <<EOF
-\ Boot script for SD boot
-patch 2drop erase claim-params
-: high-ramdisk ( -- )
- cv-load-ramdisk
- h# 22c +lp l@ 1+ memory-limit umin /ramdisk - ( new-ramdisk-adr )
- ramdisk-adr over /ramdisk move ( new-ramdisk-adr )
- to ramdisk-adr
+: set-bootpath-dev ( -- )
+ " /chosen" find-package if ( phandle )
+ " bootpath" rot get-package-property 0= if ( propval$ )
+ get-encoded-string ( bootpath$ )
+ [char] \ left-parse-string 2nip ( dn$ )
+ dn-buf place ( )
+ then
+ then
+
+ " /sd" dn-buf count sindex 0>= if
+ " sd:"
+ else
+ " u:"
+ then
+ " BOOTPATHDEV" \$set-macro
;
-' high-ramdisk to load-ramdisk
+set-bootpath-dev
" $args" to boot-file
-" sd:\syslinux\initrd0.img" to ramdisk
+" \${BOOTPATHDEV}\syslinux\initrd0.img" expand$ to ramdisk
+" \${BOOTPATHDEV}\syslinux\vmlinuz0" expand$ to boot-device
unfreeze
-boot sd:\syslinux\vmlinuz0
+boot
EOF
- if [ -n "$xosd" ]; then
- mkdir $USBMNT/boot
- cp $USBMNT/olpc-sd.fth $USBMNT/boot/olpc.fth
- elif [ -n "$xousb" ]; then
- mkdir $USBMNT/boot
- cp $USBMNT/olpc-usb.fth $USBMNT/boot/olpc.fth
- fi
fi
echo "Installing boot loader"
15 years, 6 months
Livecd-creator and source rpms
by Rahul Sundaram
Hi,
If I am building and distributing a ISO containing Fedora packages, I
would also want to distribute the equivalent source ISO. Unlike Pungi
which does this by default, livecd-creator doesn't seem to have a easy
way to do this. It especially becomes tricky if I am including not just
the GA packages but also including updates. Can livecd-creator be
modified to build source ISO images as well?
Rahul
15 years, 6 months
Re: [Fedora-livecd-list] xconfig does not work
by Todd Cooper
How do I switch to a tty from the GUI?
Is there a key sequence for X windows once booted to go back to a regular login prompt?
Todd M. Cooper
todd_cooper(a)yahoo.com
----- Original Message ----
From: Jeremy Katz <katzj(a)redhat.com>
To: Todd Cooper <todd(a)world.std.com>; fedora-livecd-list(a)redhat.com
Sent: Thursday, October 2, 2008 10:39:35 AM
Subject: Re: [Fedora-livecd-list] xconfig does not work
On Wed, 2008-10-01 at 09:13 -0700, Todd Cooper wrote:
> I added small things to the desktop kickstart (attached) and the
> xconfig no longer works.
> The biggest change is adding mysql to the rpms to be added.
> The .ks file attached has xconfig commented out.
>
> When I boot it comes up with the X login and when I click on the login
> user, it starts the login and then goes back to the login screen.
> Even if I login as root it does the same thing.
You probably are missing whatever the xsession is trying to run. If you
switch to a tty and check ~/.xsession-errors, you'll probably see
something more enlightening
Jeremy
--
Fedora-livecd-list mailing list
Fedora-livecd-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/fedora-livecd-list
15 years, 6 months
3 commits - tools/livecd-iso-to-disk.sh
by Jeremy Katz
tools/livecd-iso-to-disk.sh | 36 ++++++++++++++++++++++++++++++------
1 file changed, 30 insertions(+), 6 deletions(-)
New commits:
commit 79ad977f7ae66dd4cdcbc6e3e6c224711a65eca1
Author: Jeremy Katz <katzj(a)redhat.com>
Date: Thu Oct 2 22:24:47 2008 -0400
Set up persistent /home for the XO on the internal nand
Unless explicitly requested otherwise with --xo-no-home, use the /home
on the XO's NAND by default for /home. This helps us to keep the memory
footprint a little bit lower
diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
index 27e59ec..5c20640 100755
--- a/tools/livecd-iso-to-disk.sh
+++ b/tools/livecd-iso-to-disk.sh
@@ -266,6 +266,9 @@ while [ $# -gt 2 ]; do
xo=1
xousb=1
;;
+ --xo-no-home)
+ xonohome=1
+ ;;
--extra-kernel-args)
kernelargs=$2
shift
@@ -496,6 +499,9 @@ fi
if [ -n "$xo" ]; then
echo "Setting up /olpc-usb.fth file"
args=$(egrep "^[ ]*append" $USBMNT/$SYSLINUXPATH/isolinux.cfg |head -n1 |sed -e 's/.*initrd=[^ ]*//')
+ if [ -n "$xonohome" -a ! -f $USBMNT/LiveOS/$HOMEFILE ]; then
+ args="$args persistenthome=mtd0"
+ fi
cat > $USBMNT/olpc-usb.fth <<EOF
\ Boot script for USB boot
patch 2drop erase claim-params
commit 5e8bf77037d0a83a95837111fd87263b7f5e0f9d
Author: Jeremy Katz <katzj(a)redhat.com>
Date: Thu Oct 2 22:24:05 2008 -0400
Switch all references to home.img to be $HOMEFILE
diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
index 7cb97af..27e59ec 100755
--- a/tools/livecd-iso-to-disk.sh
+++ b/tools/livecd-iso-to-disk.sh
@@ -226,6 +226,7 @@ fi
cryptedhome=1
keephome=1
+HOMEFILE="home.img"
while [ $# -gt 2 ]; do
case $1 in
--overlay-size-mb)
@@ -341,7 +342,7 @@ mount $mountopts $USBDEV $USBMNT || exitclean
trap exitclean SIGINT SIGTERM
-if [ -f "$USBMNT/LiveOS/home.img" -a -n "$keephome" -a -n "$homesizemb" ]; then
+if [ -f "$USBMNT/LiveOS/$HOMEFILE" -a -n "$keephome" -a -n "$homesizemb" ]; then
echo "ERROR: Requested keeping existing /home and specified a size for /home"
echo "Please either don't specify a size or specify --delete-home"
exitclean
@@ -355,7 +356,7 @@ else
fi
if [ -d $USBMNT/LiveOS ]; then
tbd=$(du -s -B 1M $USBMNT/LiveOS | awk {'print $1;'})
- [ -f $USBMNT/LiveOS/home.img ] && homesz=$(du -s -B 1M $USBMNT/LiveOS/home.img | awk {'print $1;'})
+ [ -f $USBMNT/LiveOS/$HOMEFILE ] && homesz=$(du -s -B 1M $USBMNT/LiveOS/$HOMEFILE | awk {'print $1;'})
[ -n "$homesz" -a -n "$keephome" ] && tbd=$(($tbd - $homesz))
else
tbd=0
@@ -374,7 +375,7 @@ fi
if [ -d $USBMNT/LiveOS -a -z "$force" ]; then
echo "Already set up as live image."
- if [ -z "$keephome" -a -e $USBMNT/LiveOS/home.img ]; then
+ if [ -z "$keephome" -a -e $USBMNT/LiveOS/$HOMEFILE ]; then
echo "WARNING: Persistent /home will be deleted!!!"
echo "Press Enter to continue or ctrl-c to abort"
read
@@ -382,7 +383,7 @@ if [ -d $USBMNT/LiveOS -a -z "$force" ]; then
echo "Deleting old OS in fifteen seconds..."
sleep 15
- [ -e "$USBMNT/LiveOS/home.img" -a -n "$keephome" ] && mv $USBMNT/LiveOS/home.img $USBMNT/home.img
+ [ -e "$USBMNT/LiveOS/$HOMEFILE" -a -n "$keephome" ] && mv $USBMNT/LiveOS/$HOMEFILE $USBMNT/$HOMEFILE
fi
rm -rf $USBMNT/LiveOS
@@ -392,7 +393,7 @@ echo "Copying live image to USB stick"
[ -z "$mactel" -a ! -d $USBMNT/$SYSLINUXPATH ] && mkdir -p $USBMNT/$SYSLINUXPATH
[ -n "$mactel" -a ! -d $USBMNT/EFI/boot ] && mkdir -p $USBMNT/EFI/boot
[ ! -d $USBMNT/LiveOS ] && mkdir $USBMNT/LiveOS
-[ -n "$keephome" -a -f "$USBMNT/home.img" ] && mv $USBMNT/home.img $USBMNT/LiveOS/home.img
+[ -n "$keephome" -a -f "$USBMNT/$HOMEFILE" ] && mv $USBMNT/$HOMEFILE $USBMNT/LiveOS/$HOMEFILE
# cases without /LiveOS are legacy detection, remove for F10
if [ -f $CDMNT/LiveOS/squashfs.img ]; then
cp $CDMNT/LiveOS/squashfs.img $USBMNT/LiveOS/squashfs.img || exitclean
@@ -465,7 +466,6 @@ fi
if [ -n "$homesizemb" ]; then
echo "Initializing persistent /home"
- HOMEFILE=home.img
if [ "$USBFS" = "vfat" ]; then
# vfat can't handle sparse files
dd if=/dev/zero of=$USBMNT/LiveOS/$HOMEFILE count=$homesizemb bs=1M
commit e4b03a3e249ecf550b40b659914b84210989b0e3
Author: Jeremy Katz <katzj(a)redhat.com>
Date: Tue Sep 23 13:01:51 2008 -0400
Temporarily patch up ramdisk handling for XO via olpc.fth (from Mitch Bradley)
The XO firmware is loading the initrd at the wrong address which is what
was breaking the use of standard Fedora kernels. This does runtime
patching of ofw from the boot file until there's a new firmware
revision that we can require.
OFW code is from Mitch Bradley <wmb AT laptop DOT org>
diff --git a/tools/livecd-iso-to-disk.sh b/tools/livecd-iso-to-disk.sh
index b9b877b..7cb97af 100755
--- a/tools/livecd-iso-to-disk.sh
+++ b/tools/livecd-iso-to-disk.sh
@@ -498,6 +498,15 @@ if [ -n "$xo" ]; then
args=$(egrep "^[ ]*append" $USBMNT/$SYSLINUXPATH/isolinux.cfg |head -n1 |sed -e 's/.*initrd=[^ ]*//')
cat > $USBMNT/olpc-usb.fth <<EOF
\ Boot script for USB boot
+patch 2drop erase claim-params
+: high-ramdisk ( -- )
+ cv-load-ramdisk
+ h# 22c +lp l@ 1+ memory-limit umin /ramdisk - ( new-ramdisk-adr )
+ ramdisk-adr over /ramdisk move ( new-ramdisk-adr )
+ to ramdisk-adr
+;
+' high-ramdisk to load-ramdisk
+
" $args" to boot-file
" u:\syslinux\initrd0.img" to ramdisk
unfreeze
@@ -507,6 +516,15 @@ EOF
echo "Setting up /olpc-sd.fth file"
cat > $USBMNT/olpc-sd.fth <<EOF
\ Boot script for SD boot
+patch 2drop erase claim-params
+: high-ramdisk ( -- )
+ cv-load-ramdisk
+ h# 22c +lp l@ 1+ memory-limit umin /ramdisk - ( new-ramdisk-adr )
+ ramdisk-adr over /ramdisk move ( new-ramdisk-adr )
+ to ramdisk-adr
+;
+' high-ramdisk to load-ramdisk
+
" $args" to boot-file
" sd:\syslinux\initrd0.img" to ramdisk
unfreeze
15 years, 6 months
imgcreate/live.py
by Jeremy Katz
imgcreate/live.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit cb364b5faeecb22bc8ecd73dd94feee4cf3ad4e6
Author: Jeremy Katz <katzj(a)redhat.com>
Date: Tue Sep 30 12:15:42 2008 -0400
SD needs sdhci-pci now as well
diff --git a/imgcreate/live.py b/imgcreate/live.py
index f98f76c..17d3037 100644
--- a/imgcreate/live.py
+++ b/imgcreate/live.py
@@ -220,7 +220,7 @@ class LiveImageCreatorBase(LoopImageCreator):
f.write('MODULES+="firewire-sbp2 firewire-ohci "\n')
f.write('MODULES+="sbp2 ohci1394 ieee1394 "\n')
elif module == "=mmc":
- f.write('MODULES+="mmc_block sdhci "\n')
+ f.write('MODULES+="mmc_block sdhci sdhci-pci "\n')
elif module == "=pcmcia":
f.write('MODULES+="pata_pcmcia "\n')
else:
15 years, 6 months
Persistent Overlay on LiveCD
by Justin Hochstetler
Hi all,
Apologies if this is in a FAQ somewhere; I didn't see it if so.
Is there a way with Fedora 9 or Fedora 10 to use a LiveCD and have a
persistent overlay on another device, such as (obviously) a USB stick,
without also installing Fedora itself to the stick?
Some of the PCs I work with boot the CD okay, but tend to not like the
USB as much, at least where booting-from is concerned.
Thanks,
Justin
15 years, 6 months
Generic user and scripts
by Rahul Sundaram
Hi,
The Fedora kickstart files setup a user called "Fedora" and runs some
init scripts under the same name. In my remix, I have retained the same
name but it might be beneficial for such remixes and any other
derivatives if we used something generic such as "system" instead of
"Fedora". Comments?
Rahul
15 years, 6 months
xconfig does not work
by Todd Cooper
I added small things to the desktop kickstart (attached) and the xconfig no longer works.
The biggest change is adding mysql to the rpms to be added.
The .ks file attached has xconfig commented out.
When I boot it comes up with the X login and when I click on the login user, it starts the login and then goes back to the login screen.
Even if I login as root it does the same thing.
Help?
Thanks.
-Todd Cooper
15 years, 6 months