From d56124bb5442aeff962b73e8d2f128dd170936ed Mon Sep 17 00:00:00 2001 From: Michael Larson Date: Mon, 21 Jun 2010 17:29:10 -0700 Subject: fix for bug 5716 --- scripts/vyatta-config-loader.pl | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/scripts/vyatta-config-loader.pl b/scripts/vyatta-config-loader.pl index a03a0e4..809c5dd 100755 --- a/scripts/vyatta-config-loader.pl +++ b/scripts/vyatta-config-loader.pl @@ -112,6 +112,14 @@ foreach (@all_nodes) { } } +$ret = system("$commit_cmd"); +if ($ret >> 8) { + print OLDOUT "Commit failed at boot\n"; + print WARN "Commit failed at boot\n"; + system("$cleanup_cmd"); + # exit normally after cleanup (or should we exit with error?) +} + # Now deactivate these nodes for (@deactivate_nodes) { my $cmd = "$CWRAPPER deactivate " . $_; @@ -126,6 +134,7 @@ if ($ret >> 8) { # exit normally after cleanup (or should we exit with error?) } + # really clean up system("$CWRAPPER end"); restore_fds(); -- cgit v1.2.3