From 9acd61c6749af849c5825e16b4af4f664f1a7b8c Mon Sep 17 00:00:00 2001 From: Dirk von Suchodoletz Date: Mon, 15 Oct 2007 21:15:18 +0000 Subject: Fixes for changed directories in /etc (SuSE), fix for improper tar filter while copying etc/ data (bind mounts). Do not copy splashy stuff if not used and remove splashy after using ... git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1387 95ad53e4-c205-0410-b2fa-d234c58c8868 --- initramfs/distro-specs/suse/config-10.3 | 4 ++-- initramfs/distro-specs/suse/config-default | 2 +- initramfs/initrd-stuff/bin/servconfig | 5 +++-- initramfs/initrd-stuff/init | 6 +++--- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/initramfs/distro-specs/suse/config-10.3 b/initramfs/distro-specs/suse/config-10.3 index 7a4a320c..2474dfa3 100644 --- a/initramfs/distro-specs/suse/config-10.3 +++ b/initramfs/distro-specs/suse/config-10.3 @@ -33,8 +33,8 @@ D_INITSCRIPTS="boot.udev boot.proc boot.klog boot.loadmodules boot.clock \ boot.sysctl boot.ipconfig boot.swap" -D_RODIRSINRW="/etc/opt/gnome/gconf /var/adm /var/lib/texmf /var/lib/rpm \ -/var/cache/fontconfig" +D_RODIRSINRW="/etc/gconf /etc/opt/kde3/share/icons /var/adm /var/lib/texmf \ +/var/lib/rpm /var/cache/fontconfig" #D_HWMODTOIGNORE="i8xx-tco ichxrom snd-atiixp-modem intel-rng pata_atiixp" D_HWMODTOIGNORE="i8xx-tco ichxrom snd-atiixp-modem intel-rng" D_XORGBIN=/usr/bin/Xorg diff --git a/initramfs/distro-specs/suse/config-default b/initramfs/distro-specs/suse/config-default index 94fbac4e..8c75e4f7 100644 --- a/initramfs/distro-specs/suse/config-default +++ b/initramfs/distro-specs/suse/config-default @@ -34,7 +34,7 @@ # during client bootup, path and file relative to /etc D_SYSCONFDIR=/sysconfig -D_ETCEXCL="opt/gnome/gconf/*\n*.old\n*-\n*.rpmorig\n*.rpmnew\n\ +D_ETCEXCL="*.old\n*-\n*.rpmorig\n*.rpmnew\n\ *.YaST2save\netc/autoinstall\nlogrotate*\nbootloader\n*~\n\ *.SuSEconfig.saved\npptp.d\nisdn\nyouservers\nhardware/hwcfg*\n\ X11/xdm/pixmaps\n*.rpmsave\ndhclient*script\nxorg.conf.*" diff --git a/initramfs/initrd-stuff/bin/servconfig b/initramfs/initrd-stuff/bin/servconfig index d26a4213..dd768190 100755 --- a/initramfs/initrd-stuff/bin/servconfig +++ b/initramfs/initrd-stuff/bin/servconfig @@ -195,7 +195,8 @@ if [ ${nosplash} = 0 ]; then D_INITSCRIPTS="${D_INITSCRIPTS} splashy.stop" d_mkrlscript init splashy.stop "Stopping Splashy ..." echo -e "\t/var/lib/openslx/bin/splashy_update exit 2>/dev/null - \tkillall -9 splashy" >>/mnt/etc/${D_INITDIR}/splashy.stop + \tkillall -9 splashy\n\trm -f /var/lib/openslx/bin/splashy*" \ + >>/mnt/etc/${D_INITDIR}/splashy.stop d_mkrlscript close splashy.stop "" fi @@ -445,7 +446,7 @@ testmkd /mnt/var/lib/openslx/themes/displaymanager testmkd /mnt/var/lib/openslx/bin [ -d /usr/share/themes/displaymanager ] && \ cp -a /usr/share/themes/displaymanager /mnt/var/lib/openslx/themes -[ -d /etc/splashy ] && ( cp -a /etc/splashy /mnt/etc; \ +[ -d /etc/splashy -a ${nosplash} = 0 ] && ( cp -a /etc/splashy /mnt/etc; \ cp -a /bin/splashy* /mnt/var/lib/openslx/bin ) ############################################################################# diff --git a/initramfs/initrd-stuff/init b/initramfs/initrd-stuff/init index 9c12ebbe..b126a744 100755 --- a/initramfs/initrd-stuff/init +++ b/initramfs/initrd-stuff/init @@ -665,12 +665,12 @@ elif [ -z "${cowloop}" ] ; then # see above ... ldcfg # save the RO directories mentioned in the distro-specific - # config to a temporary directory. They will lateron be restored + # config to a temporary directory. They will later on be restored for path in ${D_RODIRSINRW}; do if [ -d /mnt/${path} ] ; then - list=${path}" "${list} + list="${path} ${list}" # exclude them from etc copy process too - echo ${path}|sed -e "s,/root/,," >>/tmp/etc.exclude + echo "${path}/*"|sed -e "s,/root/,,;s,^/,," >>/tmp/etc.exclude mkdir -p /root/${path} >/dev/null 2>&1 mount -n --bind /mnt/${path} /root/${path} >/dev/null 2>&1 fi -- cgit v1.2.3-55-g7522