summaryrefslogtreecommitdiff
path: root/scripts/install-system
diff options
context:
space:
mode:
authorRick Balocca <rbalocca@vyatta.com>2008-11-20 18:58:37 -0800
committerRick Balocca <rbalocca@vyatta.com>2008-11-20 18:58:37 -0800
commit081b37958049ed703dce5f4c7a9c39bcbf3f4a4a (patch)
tree34a748b587c350e7502cfa3cfde44f5bab0e05d2 /scripts/install-system
parent147fc08625ce3245c32367a4dac227b71f05b562 (diff)
parenta91be4ee51527f2ed975a36d433101ec720437a4 (diff)
downloadvyatta-cfg-quagga-081b37958049ed703dce5f4c7a9c39bcbf3f4a4a.tar.gz
vyatta-cfg-quagga-081b37958049ed703dce5f4c7a9c39bcbf3f4a4a.zip
Merge branch 'islavista' into jenner
Diffstat (limited to 'scripts/install-system')
-rwxr-xr-xscripts/install-system27
1 files changed, 27 insertions, 0 deletions
diff --git a/scripts/install-system b/scripts/install-system
index 65a31571..2cd16d65 100755
--- a/scripts/install-system
+++ b/scripts/install-system
@@ -271,6 +271,33 @@ check_for_old_raid () {
echo "Using RAID partition $INSTALL_DRIVE"
+ raid_degraded=`cat /sys/block/$INSTALL_DRIVE/md/degraded`
+ raid_sync_action=`cat /sys/block/$INSTALL_DRIVE/md/sync_action`
+
+ if [ "$raid_degraded" = "1" ]; then
+ echo
+ if [ "$raid_sync_action" = "recover" ]; then
+ echo "Error: This RAID set is degraded and is in the process of"
+ echo "rebuilding. It is not safe to install onto it while the"
+ echo "rebuild is in progress. Please wait for the rebuild to"
+ echo "complete and then re-start the installation. You may"
+ echo "monitor the progress of the RAID rebuild with the"
+ echo "command:"
+ echo
+ echo " show raid $INSTALL_DRIVE"
+ echo
+ exit 1
+ fi
+ echo "Warning: This RAID set is degraded, but is not in the"
+ echo "process of rebuilding. It is safe to perform the installation"
+ echo "onto a degraded RAID set that is not in the process of"
+ echo "rebuilding. You may stop the installation now and rebuild the"
+ echo "RAID set, or continue installing onto it. If you continue"
+ echo "installing, do not attempt to rebuild the RAID set until the"
+ echo "installation has completed and you have rebooted the system."
+ echo
+ fi
+
warn_of_dire_consequences
ROOT_PARTITION=$INSTALL_DRIVE