CS-14421: Clean /etc/network/interfaces when sysytemvm reboot In order to make sure next time, booting process would use cloud-early-config's setup, rather than networking scripts to bring up interfaces.
Reviewed-by: Kelven Yang Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/985757ff Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/985757ff Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/985757ff Branch: refs/heads/master Commit: 985757ffe6c5ef2363f2ab1a639cc1c325545364 Parents: 2c001bb Author: Sheng Yang <[email protected]> Authored: Tue May 29 16:45:52 2012 -0700 Committer: Sheng Yang <[email protected]> Committed: Thu May 31 17:57:55 2012 -0700 ---------------------------------------------------------------------- .../debian/config/etc/init.d/cloud-early-config | 9 ++++----- 1 files changed, 4 insertions(+), 5 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/985757ff/patches/systemvm/debian/config/etc/init.d/cloud-early-config ---------------------------------------------------------------------- diff --git a/patches/systemvm/debian/config/etc/init.d/cloud-early-config b/patches/systemvm/debian/config/etc/init.d/cloud-early-config index 9c0d189..19f87c2 100755 --- a/patches/systemvm/debian/config/etc/init.d/cloud-early-config +++ b/patches/systemvm/debian/config/etc/init.d/cloud-early-config @@ -696,11 +696,8 @@ setup_elbvm() { setup_default() { cat > /etc/network/interfaces << EOF -auto lo eth0 +auto lo iface lo inet loopback - -iface eth0 inet static - EOF } @@ -895,7 +892,9 @@ start) ;; stop) - log_action_begin_msg "Stopping cloud-early-config (noop)" + log_action_begin_msg "Stopping cloud-early-config" + #Override old system's interface setting + setup_default; log_action_end_msg 0 ;;
