mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-16 22:50:10 +03:00
M #-: Make probes more robust
This commit is contained in:
parent
392e28768e
commit
c8251dc733
@ -67,7 +67,7 @@ module Firecracker
|
||||
|
||||
response = client.get('machine-config')
|
||||
rescue StandardError, FirecrackerError
|
||||
return
|
||||
return {}
|
||||
end
|
||||
|
||||
###################################################################
|
||||
@ -89,7 +89,7 @@ module Firecracker
|
||||
|
||||
response = client.get('')
|
||||
rescue StandardError, FirecrackerError
|
||||
return
|
||||
return {}
|
||||
end
|
||||
|
||||
###################################################################
|
||||
|
@ -23,7 +23,11 @@ require 'fileutils'
|
||||
class DSMonitor
|
||||
|
||||
def initialize(config)
|
||||
@ds_location = config.elements['DATASTORE_LOCATION'].text.to_s
|
||||
begin
|
||||
@ds_location = config.elements['DATASTORE_LOCATION'].text.to_s
|
||||
rescue
|
||||
end
|
||||
|
||||
@ds_location ||= '/var/lib/one/datastores'
|
||||
|
||||
FileUtils.mkdir_p @ds_location
|
||||
|
@ -27,7 +27,11 @@ rescue StandardError => e
|
||||
exit(-1)
|
||||
end
|
||||
|
||||
begin
|
||||
ds_location = config.elements['DATASTORE_LOCATION'].text.to_s
|
||||
rescue
|
||||
end
|
||||
|
||||
ds_location ||= '/var/lib/one/datastores'
|
||||
|
||||
Dir.chdir ds_location
|
||||
|
Loading…
x
Reference in New Issue
Block a user