I'm trying to create a custom live cd of Sabayon with Molecule, I followed this wiki:
http://wiki.sabayon.org/index.php?title=HOWTO:_Using_Molecule_Example
in wich there is an example, copying that example and adding few lines I've created this spec file:
- Code: Select all
# Sabayon Linux 5 x86 Molecule spec file
# squashfs, mkisofs needed
# pre chroot command, example, for 32bit chroots on 64bit system, you always have to append "linux32"
# this is useful for inner_chroot_script
# prechroot:
# Release string
release_string: CustomSabayon
# Release Version
release_version: 0.1
# Release Version string description
release_desc: x86 KDE
# Define an alternative execution strategy, in this case, the value must be
# "iso_remaster"
execution_strategy: iso_remaster
# Path to source ISO file (MANDATORY)
source_iso: /home/alex/Sabayon Live/iso/Sabayon_Linux_DAILY_x86_K.iso
# Outer chroot script command, to be executed outside destination chroot before
# before entering it (and before inner_chroot_script)
outer_chroot_script: /home/alex/Desktop/alex/Sabayon Live/remaster_pre.sh
#Inner chroot script command, to be executed inside destination chroot before packing it
# - kmerge.sh - setup kernel bins
inner_chroot_script: /home/alex/Desktop/alex/Sabayon Live/inner_chroot_script.sh
# Outer chroot script command, to be executed outside destination chroot before
# before entering it (and AFTER inner_chroot_script)
outer_chroot_script_after: /home/alex/Desktop/alex/Sabayon Live/remaster_post.sh
# Extra mkisofs parameters, perhaps something to include/use your bootloader
extra_mkisofs_parameters: -b isolinux/isolinux.bin -c isolinux/boot.cat
# Destination directory for the ISO image path (MANDATORY)
destination_iso_directory: /home/alex/Sabayon Live/final
#FOR CD IMAGE Destination ISO image name, call whatever you want.iso, not mandatory
destination_iso_image_name: Sabayon_Custom_x86_K
#FOR DVD IMAGE Output iso image title
#iso_title: Sabayon_Custom_x86_K
# Merge directory with destination LiveCD root
# merge_livecd_root: /put/more/files/onto/CD/root
# List of packages that would be removed from chrooted system (comma separated)
#packages_to_remove: foo, foo2, foo3, foo4, foo5
# Custom shell call to packages removal (default is: equo remove)
# custom_packages_remove_cmd:
# List of packages that would be added from chrooted system (comma separated)
#packages_to_add: foo, foo2, foo3, foo4, foo5
# Custom shell call to packages add (default is: equo install)
# custom_packages_add_cmd:
# Custom command for updating repositories (default is: equo update)
# repositories_update_cmd:
# Determine whether repositories update should be run (if packages_to_add is set)
# (default is: no), values are: yes, no.
execute_repositories_update: yes
# Directories to remove completely (comma separated)
paths_to_remove:
/var/lib/entropy/client/database/amd64/sabayonlinux.org,
/boot/grub/grub.conf,
/root/.subversion,
/lib/udev-state/devices.tar.bz2,
/var/log/scrollkeeper.log, /var/log/genkernel.log,
/var/log/emerge.log, /usr/tmp/portage/*,
/root/.bash_history,
/usr/share/slocate/slocate.db,
/root/test-results.txt,
/root/test.sh,
/usr/portage/distfiles/*,
/usr/portage/packages/*,
/root/.revdep*,
/install-data/games/*,
/var/lib/entropy/store/*,
/var/log/entropy/*,
/var/lib/entropy/caches/*,
/var/lib/entropy/smartapps/amd64/*,
/var/lib/entropy/smartapps/amd64/*,
/var/lib/entropy/tmp/*,
/var/lib/entropy/packages*/*,
/var/tmp/entropy/*,
/*.txt,
/usr/portage/a*,
/usr/portage/b*,
/usr/portage/c*,
/usr/portage/d*,
/usr/portage/e*,
/usr/portage/f*,
/usr/portage/g*,
/usr/portage/h*,
/usr/portage/i*,
/usr/portage/j*,
/usr/portage/k*,
/usr/portage/licenses,
/usr/portage/lxde*,
/usr/portage/m*,
/usr/portage/n*,
/usr/portage/o*,
/usr/portage/packages,
/usr/portage/pe*,
/usr/portage/q*,
/usr/portage/r*,
/usr/portage/s*,
/usr/portage/t*,
/usr/portage/u*,
/usr/portage/v*,
/usr/portage/w*,
/usr/portage/x*,
/usr/portage/y*,
/usr/portage/z*,
/etc/ssh/ssh_host_*,
/var/run/screen*,
/entropy,
/tmp/equoerror.txt,
/var/cache/man,
/var/lib/entropy/glsa/*,
/opt/anaconda/usr/lib32,
/opt/anaconda/usr/share/anaconda/po,
/var/log/entropy/*.log,
/etc/mtab,
/boot/grub/grub.c*,
/tmp/.ICE-unix*,
/tmp/*.txt,
/tmp/.X*,
/boot/grub/device.map
# Directories to empty (comma separated)
paths_to_empty:
/home/sabayonuser/.thumbnails/,
/var/tmp,
/root/.ccache,
/var/tmp/portage,
/var/tmp/ccache,
/var/tmp/portage-pkg,
/var/tmp/binpkgs,
/var/lib/entropy/portage,
/var/lib/entropy/logs,
/var/lib/entropy/packages/amd64/4,
/var/cache/genkernel
I've also copied the two scripts remaster_pre.sh and remaster_post.sh and created my own inner_chroot_script.sh in order to install some additional software, these scripts are the following:
remaster_pre.sh:
- Code: Select all
#!/bin/sh
PKGS_DIR="/sabayon/remaster/pkgs"
CHROOT_PKGS_DIR="${CHROOT_DIR}/var/lib/entropy/packages"
[[ ! -d "${PKGS_DIR}" ]] && mkdir -p "${PKGS_DIR}"
[[ ! -d "${CHROOT_PKGS_DIR}" ]] && mkdir -p "${CHROOT_PKGS_DIR}"
echo "Mounting packages over"
rm -rf "${CHROOT_PKGS_DIR}"/*
cp ${PKGS_DIR}/* "${CHROOT_PKGS_DIR}"/ -Ra
exit 0
remaster_post.sh:
- Code: Select all
#!/bin/sh
PKGS_DIR="/sabayon/remaster/pkgs"
CHROOT_PKGS_DIR="${CHROOT_DIR}/var/lib/entropy/packages"
echo "Merging back packages"
cp "${CHROOT_PKGS_DIR}"/* "${PKGS_DIR}"/ -Ra
rm -rf "${CHROOT_PKGS_DIR}"{,-nonfree,-restricted}/*
cp /home/alex/Sabayon Live/background/background.png "${CHROOT_DIR}/usr/share/backgrounds/background.png"
is_64=$(file "${CHROOT_DIR}"/bin/bash | grep "x86-64")
if [ -n "${is_64}" ]; then
echo "equo cleanup" | chroot "${CHROOT_DIR}"
else
echo "equo cleanup" | linux32 chroot "${CHROOT_DIR}"
fi
inner_chroot_script.sh:
- Code: Select all
#!/bin/bash
# Package manager update
equo update
equo install entropy equo --multifetch=10
# Unwanted package removal
equo remove kopete
#Software installation
equo install www-client/chromium www-client/opera net-analyzer/wireshark kde-base/step media-gfx/blender app-cdr/acetoneiso media-sound/audacity kde-base/kmplot media-gfx/inkscape net-im/amsn amsn-skins net-im/emesene dev-util/kdevelop net-print/hplip net-im/skype net-analyzer/wireshark apache arping eclipse-sdk ethtool gnu-netcat gparted hping sys-boot/unetbootin playonlinux sun-jdk tcpdump tuprolog virtualbox-bin virtualbox-guest-additions virtualbox-modules --multifetch=10
equo conf update
# Java configuration
java-config -S sun-jdk-1.6
java-config-2 -S sun-jdk-1.6
# Modules configuration
echo modules=\"vboxdrv vboxnetflt vboxnetadp b43\" >> /etc/conf.d/modules
#Cleanup
equo cleanup
equo rescue vacuum
But when I try to run molecule I get this:
- Code: Select all
Sabayon-Alex Sabayon Live # molecule sabayon.spec
>> (0/4) [Runner|sabayon.spec] preparing execution
>> (1/4) [Runner|sabayon.spec] executing molecule.specs.plugins.remaster_plugin.IsoUnpackHandler
>> [IsoUnpackHandler|sabayon.spec] executing pre_run
>> [IsoUnpackHandler|sabayon.spec] spawning: ['mount', '-o', 'loop', '-t', 'iso9660', u'/home/alex/Sabayon Live/iso/Sabayon_Linux_DAILY_x86_K.iso', '/var/tmp/moleculeIAKVob']
Usage: mount -V : print version
mount -h : print this help
mount : list mounted filesystems
mount -l : idem, including volume labels
So far the informational part. Next the mounting.
The command is `mount [-t fstype] something somewhere'.
Details found in /etc/fstab may be omitted.
mount -a [-t|-O] ... : mount all stuff from /etc/fstab
mount device : mount device at the known place
mount directory : mount known device here
mount -t type dev dir : ordinary mount command
Note that one does not really mount a device, one mounts
a filesystem (of the given type) found on the device.
One can also mount an already visible directory tree elsewhere:
mount --bind olddir newdir
or move a subtree:
mount --move olddir newdir
One can change the type of mount containing the directory dir:
mount --make-shared dir
mount --make-slave dir
mount --make-private dir
mount --make-unbindable dir
One can change the type of all the mounts in a mount subtree
containing the directory dir:
mount --make-rshared dir
mount --make-rslave dir
mount --make-rprivate dir
mount --make-runbindable dir
A device can be given by name, say /dev/hda1 or /dev/cdrom,
or by label, using -L label or by uuid, using -U uuid .
Other options: [-nfFrsvw] [-o options] [-p passwdfd].
For many more details, say man 8 mount .
>> [IsoUnpackHandler|sabayon.spec] iso mount failed: 1
>> [IsoUnpackHandler|sabayon.spec] executing kill
So it stop and I can't understand what it's wrong, there's someone that can kindly help me?
Thank you very much ^^


