mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-19 03:12:55 +09:00
Merge branch 'master' of opennebula.org:one
This commit is contained in:
commit
ad1f9c813c
7 files changed
+20
-5
No files matched your search
@@ -16,6 +16,8 @@
|
||||
# limitations under the License. #
|
||||
#--------------------------------------------------------------------------- #
|
||||
|
||||
export LANG=C
|
||||
|
||||
HYPERVISOR_DIR=$1.d
|
||||
ARGUMENTS=$*
|
||||
|
||||
|
||||
@@ -49,7 +49,7 @@ class GangliaHost
|
||||
self.new(xml, host)
|
||||
end
|
||||
|
||||
def self.new_fom_file(host, file)
|
||||
def self.new_from_file(host, file)
|
||||
new_with_options(host, :file => file)
|
||||
end
|
||||
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
# limitations under the License. #
|
||||
#--------------------------------------------------------------------------- #
|
||||
|
||||
export LANG=C
|
||||
|
||||
if [ -z "$ONE_LOCATION" ]; then
|
||||
ONE_LOCAL_VAR=/var/lib/one
|
||||
else
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
# limitations under the License. #
|
||||
#--------------------------------------------------------------------------- #
|
||||
|
||||
export LANG=C
|
||||
|
||||
export LIBVIRT_URI=qemu:///system
|
||||
|
||||
export QEMU_PROTOCOL=qemu
|
||||
@@ -64,11 +64,16 @@ rescue
|
||||
exit -1
|
||||
end
|
||||
|
||||
dom_info=ganglia.get_vms_information
|
||||
doms_info=ganglia.get_vms_information
|
||||
dom_id=domain.split('-').last
|
||||
|
||||
if dom_info[domain]
|
||||
info=dom_info[domain].map do |key, value|
|
||||
"#{key.to_s.upcase}=\"#{value}\""
|
||||
# Get key one-<vmid> or <vmid> key from the hash
|
||||
dom_info=doms_info[domain]
|
||||
dom_info=doms_info[dom_id] if !dom_info
|
||||
|
||||
if dom_info
|
||||
info=dom_info.map do |key, value|
|
||||
"#{key.to_s.upcase}=#{value}"
|
||||
end.join(' ')
|
||||
|
||||
puts info
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
require 'pp'
|
||||
require 'rexml/document'
|
||||
|
||||
ENV['LANG']='C'
|
||||
|
||||
module KVM
|
||||
CONF={
|
||||
:dominfo => 'virsh --connect LIBVIRT_URI --readonly dominfo',
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
# limitations under the License. #
|
||||
#--------------------------------------------------------------------------- #
|
||||
|
||||
export LANG=C
|
||||
|
||||
export XM_PATH="/usr/sbin/xm"
|
||||
export XM_CANCEL="sudo $XM_PATH destroy"
|
||||
export XM_CREATE="sudo $XM_PATH create"
|
||||
|
||||
Reference in new issue
Block a user