It has taken me some hours to find and solve the problem described below which is why I thought it would be a good idea to give my results back to the community for all those who might run into similar problems. If this problem occurs for other users as well it might be worth patching the remastersys script which is why I posted this in "Remastersys Development".
I was trying to create a new Live CD based on Debian 6 Squeeze 32 bit inside a VirtualBox-VM and got several problems: At first my CD image was a bit too big (about 900 MiB). Therefore I added the following to my remastersys.conf which had been useful in a Ubuntu installation some time ago:
# Override mksquashfs
mksquashfs() {
/usr/bin/mksquashfs "$@" -comp xz -Xdict-size 1M -b 1M
return $?
}
As the old Squeeze kernel would not boot a XZ-compressed image, it needed to be replaced with a 3.2 backports version.
After I had booted into my new live system, I realized something very annoying: After I had opened the first terminal in fluxbox and closed it, the whole GUI would no longer react on
any input, i.e. starting new terminals did not bring any window up and trying to start different applications resulted in the same behaviour. Even restarting my display manager via service xdm restart did not help. I looked at the first terminal [CTRL]-[ALT]-[F1] and saw that something tried to continuously spawn new X-servers even though my XDM had already started one. After some investigation it turned out that the interfering X-servers were started by a script called /lib/live/config/012-xinit. I found the following lines in the script:
# Checking if if package is already configured differently
if [ -e /etc/profile.d/zz-xinit.sh ] || grep -qs "startx" /etc/skel/.bash_profile
then
return
fi
if [ -e /etc/profile.d ]
then
# squeeze
cat > /etc/profile.d/zz-xinit.sh << EOF
if [ -z "\${DISPLAY}" ] && [ \$(tty) = /dev/tty1 ]
then
while true
do
startx
done
fi
EOF
After disabling the while loop and creating a new live CD, everything worked just fine. Therefore I removed my hack and created a simple file /etc/skel/.bash_profile with the following line:
# startx
This prevented the script from creating a new "X-spawner" and my live CD worked again.
System overview:
Debian 6 Squeeze 32 bit, Virtualbox OSE VM, XDM+Fluxbox, Backported 3.2 686-pae kernel, Remastersys version 2.0.23-1.
Whole remastersys.conf
# Remastersys Global Configuration File
# This is the temporary working directory and won't be included on the cd/dvd
WORKDIR="/opt/remastersys"
# Here you can add any other files or directories to be excluded from the live filesystem
# Separate each entry with a space
# Sudoers was added as you could not become
# root on the live cd anymore with sudo -s
EXCLUDES="/data /home/linux-fan /etc/sudoers.d /usr/share/mdvl/isolinux"
# Here you can change the livecd/dvd username
LIVEUSER="linux-fan"
# Here you can change the name of the livecd/dvd label
LIVECDLABEL="Debian MDVL 32"
# Here you can change the name of the ISO file that is created
CUSTOMISO="debian_mdvl_32.iso"
# Override mksquashfs...
mksquashfs() {
echo Ma_Sys.ma MKSQUASHFS used.
/usr/bin/mksquashfs "$@" -comp xz -Xdict-size 1M -b 1M
return $?
}