search for: remote_pool

Displaying 9 results from an estimated 9 matches for "remote_pool".

2009 Jul 29
0
[PATCH server] Remove ununsed utils.rb file.
...olume(db_volume) - phys_volume = StorageVolume.find(:first, :conditions => - [ "lvm_pool_id = ?", db_volume.storage_pool_id]) - - return LibvirtPool.factory(phys_volume.storage_pool) -end - -class LibvirtPool - def initialize(type, name = nil) - @remote_pool = nil - @build_on_start = true - @remote_pool_defined = false - @remote_pool_started = false - - if name == nil - @name = type + "-" + String.random_alphanumeric - else - @name = name - end - - @xml = Document.new - @xml.add_element("pool", {&qu...
2009 Jun 25
0
[PATCH] Extend timeouts on libvirt calls.
...10 +++++----- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/task-omatic/task_storage.rb b/src/task-omatic/task_storage.rb index 77363ac..8165818 100644 --- a/src/task-omatic/task_storage.rb +++ b/src/task-omatic/task_storage.rb @@ -132,7 +132,7 @@ class LibvirtPool if @remote_pool == nil @logger.debug("Defining new storage pool: #{@xml.to_s} on host: #{node.hostname}") - result = node.storagePoolDefineXML(@xml.to_s, :timeout => 60 * 2) + result = node.storagePoolDefineXML(@xml.to_s, :timeout => 60 * 10) raise "Error creating pool:...
2009 May 28
0
[PATCH server] Use fixed mount points and add timeouts to various calls.
...----- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/task-omatic/task_storage.rb b/src/task-omatic/task_storage.rb index a2188d7..4961b83 100644 --- a/src/task-omatic/task_storage.rb +++ b/src/task-omatic/task_storage.rb @@ -129,7 +129,7 @@ class LibvirtPool end if @remote_pool == nil - result = node.storagePoolDefineXML(@xml.to_s) + result = node.storagePoolDefineXML(@xml.to_s, :timeout => 60 * 2) raise "Error creating pool: #{result.text}" unless result.status == 0 @remote_pool = session.object(:object_id => result.pool) ra...
2009 May 29
0
[PATCH server] Add more debugging to storage tasks
...----- 2 files changed, 27 insertions(+), 20 deletions(-) diff --git a/src/task-omatic/task_storage.rb b/src/task-omatic/task_storage.rb index cdc0043..bfffa36 100644 --- a/src/task-omatic/task_storage.rb +++ b/src/task-omatic/task_storage.rb @@ -92,11 +92,12 @@ class LibvirtPool attr_reader :remote_pool - def initialize(type, name = nil) + def initialize(type, name = nil, logger = nil) @remote_pool = nil @build_on_start = true @remote_pool_defined = false @remote_pool_started = false + @logger = logger if name == nil @name = type + "-" + String.ra...
2009 Jul 09
1
[PATCH 1/5 ovirt-server] Add glusterfs to task-omatic API for {task_storage,utils}
...ting for the create + # operation to complete. This needs to be fixed in a better way + # however. We want to have non-sparse files for performance reasons. + @vol_xml.root.add_element("allocation").add_text('0') + + @logger.debug("Creating new volume on pool #{@remote_pool.name} - XML: #{@vol_xml.to_s}") + result = @remote_pool.createVolumeXML(@vol_xml.to_s) + raise "Error creating remote pool: #{result.text}" unless result.status == 0 + return result.volume + end + + def xmlequal?(docroot) + return (docroot.attributes['type'] =...
2009 Jul 31
0
[TAKE-2][PATCH 1/5] Add glusterfs to task-omatic API for task_storage
...ting for the create + # operation to complete. This needs to be fixed in a better way + # however. We want to have non-sparse files for performance reasons. + @vol_xml.root.add_element("allocation").add_text('0') + + @logger.debug("Creating new volume on pool #{@remote_pool.name} - XML: #{@vol_xml.to_s}") + result = @remote_pool.createVolumeXML(@vol_xml.to_s) + raise "Error creating remote pool: #{result.text}" unless result.status == 0 + return result.volume + end + + def xmlequal?(docroot) + return (docroot.attributes['type'] ==...
2009 Nov 04
4
[PATCH server] Update daemons to use new QMF.
...node' => node.object_id) pools.each do |pool| result = pool.getXMLDesc raise "Error getting xml description of pool: #{result.text}" unless result.status == 0 xml_desc = result.description + if self.xmlequal?(Document.new(xml_desc).root) @remote_pool = pool @logger.debug("Found existing storage pool #{pool.name} on host: #{node.hostname}") @@ -134,7 +135,8 @@ class LibvirtPool @logger.debug("Defining new storage pool: #{@xml.to_s} on host: #{node.hostname}") result = node.storagePoolDefineXML(@xml.to_s...
2009 Jul 13
1
[PATCH] Use volume key instead of path to identify volume.
This patch teaches taskomatic to use the volume 'key' instead of the path from libvirt to key the volume off of in the database. This fixes the duplicate iscsi volume bug we were seeing. The issue was that libvirt changed the way they name storage volumes and included a local ID that changed each time it was attached. Note that the first run with this new patch will cause duplicate
2009 May 28
0
[PATCH server] Use qpid for migration and add more debugging to taskomatic.
...r}:#{db_pool.type}:#{db_pool.target}:#{db_pool.export_path}" libvirt_pool = LibvirtPool.factory(db_pool) libvirt_pool.connect(@session, node) @@ -205,10 +215,15 @@ class TaskOmatic volume_name = db_volume.read_attribute(db_volume.volume_name) pool = libvirt_pool.remote_pool + + @logger.debug "Pool mounted: #{pool.name}; state: #{pool.state}" + volume = @session.object(:class => 'volume', 'name' => volume_name, 'storagePool' => pool.object_id) r...