CLOUDSTACK-2492: enable time sync on vmware if ntp is not installed
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/076c32db Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/076c32db Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/076c32db Branch: refs/heads/rbd-snap-clone Commit: 076c32db9a1733146a542cb23eb0515176bd5d0b Parents: c8af438 Author: Chiradeep Vittal <chirad...@apache.org> Authored: Wed May 15 15:00:19 2013 -0700 Committer: Chiradeep Vittal <chirad...@apache.org> Committed: Wed May 15 15:00:31 2013 -0700 ---------------------------------------------------------------------- .../debian/config/etc/init.d/cloud-early-config | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/076c32db/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 a457f22..893a245 100755 --- a/patches/systemvm/debian/config/etc/init.d/cloud-early-config +++ b/patches/systemvm/debian/config/etc/init.d/cloud-early-config @@ -434,6 +434,12 @@ setup_common() { ping -n -c 3 $MGMT_GW & sleep 3 pkill ping + + fi + + local hyp=$(hypervisor) + if [ "$hyp" == "vmware" ]; then + ntpq -p &> /dev/null || vmware-toolbox-cmd timesync enable fi }