summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xbin/g-i-installation.sh13
1 files changed, 11 insertions, 2 deletions
diff --git a/bin/g-i-installation.sh b/bin/g-i-installation.sh
index f268ec6f..81c6597b 100755
--- a/bin/g-i-installation.sh
+++ b/bin/g-i-installation.sh
@@ -883,8 +883,17 @@ save_logs() {
case $NAME in
debian-edu_*combi-server) sudo guestmount -a $NAME.raw -m /dev/vg_system/opt -o nonempty --ro $SYSTEM_MNT/opt || ( echo "Warning: cannot mount /dev/vg_system/opt" ; figlet "fail" )
mkdir -p $RESULTS/log/opt
- sudo cp -r $SYSTEM_MNT/opt/ltsp/amd64/var/log $RESULTS/log/opt/
- sudo chroot $SYSTEM_MNT/opt/ltsp/amd64 dpkg -l > $RESULTS/log/opt/dpkg-l || ( echo "Warning: cannot run dpkg inside the ltsp chroot." ; sudo ls -la $SYSTEM_MNT/opt/ltsp/amd64 ; figlet "fail" )
+ if [ -d $SYSTEM_MNT/opt/ltsp/amd64 ] ; then
+ LTSPARCH="amd64"
+ elif [ -d $SYSTEM_MNT/opt/ltsp/i386 ] ; then
+ LTSPARCH="i386"
+ else
+ echo "Warning: no LTSP chroot found."
+ fi
+ if [ ! -z "$LTSPARCH" ] ; then
+ sudo cp -r $SYSTEM_MNT/opt/ltsp/$LTSPARCH/var/log $RESULTS/log/opt/
+ sudo chroot $SYSTEM_MNT/opt/ltsp/$LTSPARCH dpkg -l > $RESULTS/log/opt/dpkg-l || ( echo "Warning: cannot run dpkg inside the ltsp chroot." ; sudo ls -la $SYSTEM_MNT/opt/ltsp/$LTSPARCH ; figlet "fail" )
+ fi
sudo umount -l $SYSTEM_MNT/opt || ( echo "Warning: cannot un-mount $SYSTEM_MNT/opt" ; figlet "fail" )
;;
*) ;;