diff options
author | Jonathan Bauer | 2016-07-12 15:22:53 +0200 |
---|---|---|
committer | Jonathan Bauer | 2016-07-12 15:22:53 +0200 |
commit | 81bb905ae0a741e6241725301f8ca8028f8a0aee (patch) | |
tree | 2c2b591afb44a9be955cce8cfb06aa3e65d594fb /remote/rootfs | |
parent | Merge branch 'master' of git.openslx.org:openslx-ng/tm-scripts (diff) | |
download | tm-scripts-81bb905ae0a741e6241725301f8ca8028f8a0aee.tar.gz tm-scripts-81bb905ae0a741e6241725301f8ca8028f8a0aee.tar.xz tm-scripts-81bb905ae0a741e6241725301f8ca8028f8a0aee.zip |
[rfs-s31] don't kernel panic if we could not download the config-remote
Diffstat (limited to 'remote/rootfs')
-rw-r--r-- | remote/rootfs/rootfs-stage31/data/inc/activate_sysconfig | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/remote/rootfs/rootfs-stage31/data/inc/activate_sysconfig b/remote/rootfs/rootfs-stage31/data/inc/activate_sysconfig index 39680afc..2903e5e4 100644 --- a/remote/rootfs/rootfs-stage31/data/inc/activate_sysconfig +++ b/remote/rootfs/rootfs-stage31/data/inc/activate_sysconfig @@ -98,6 +98,17 @@ HEREEND # fetch_sysconfig || drop_shell "Could not download remote config" +if ! ash -n "${CONFIG}-remote"; then + echo -e "\n\tFATAL: Could not download configuration!" + echo -e "\tAborting boot since the system would be in an unusable state." + echo -en "\tRebooting in 60 seconds" + timeout=60 + while [ $(( timeout-- )) -gt 0 ]; do + echo -n "." + sleep 1 + done + echo b > /proc/sysrq-trigger +fi . "${CONFIG}-remote" || drop_shell "Could not source remote config" fetch_config_files || drop_shell "Could not download config.tgz" update_sysconfig || drop_shell "Could not update sysconfig" |