1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-01-03 01:17:41 +03:00

feature #3848: Remove VN_MAD from Host in oned. Remove VMWare driver in

core
This commit is contained in:
Ruben S. Montero 2016-04-07 11:06:43 +02:00
parent 7816a7912b
commit 67ba59ada1
18 changed files with 72 additions and 742 deletions

View File

@ -276,7 +276,6 @@ public:
const string& hostname, const string& hostname,
int cid, int cid,
const string& vmm, const string& vmm,
const string& vnm,
const string& tmm, const string& tmm,
const string& ds_location, const string& ds_location,
int ds_id, int ds_id,
@ -323,7 +322,6 @@ private:
int cid; int cid;
string vmm_mad_name; string vmm_mad_name;
string vnm_mad_name;
string tm_mad_name; string tm_mad_name;
string ds_location; string ds_location;

View File

@ -215,15 +215,6 @@ public:
return vmm_mad_name; return vmm_mad_name;
}; };
/**
* Retrieves VNM mad name
* @return string vnm mad name
*/
const string& get_vnm_mad() const
{
return vnm_mad_name;
};
/** /**
* Retrieves IM mad name * Retrieves IM mad name
* @return string im mad name * @return string im mad name
@ -535,11 +526,6 @@ private:
*/ */
string vmm_mad_name; string vmm_mad_name;
/**
* Name of the VN driver used to manage networking in this host
*/
string vnm_mad_name;
/** /**
* If Host State = MONITORED last time it got fully monitored or 1 Jan 1970 * If Host State = MONITORED last time it got fully monitored or 1 Jan 1970
* Host State = MONITORING* last time it got a signal to be monitored * Host State = MONITORING* last time it got a signal to be monitored
@ -590,7 +576,6 @@ private:
const string& hostname, const string& hostname,
const string& im_mad_name, const string& im_mad_name,
const string& vmm_mad_name, const string& vmm_mad_name,
const string& vnm_mad_name,
int cluster_id, int cluster_id,
const string& cluster_name); const string& cluster_name);

View File

@ -51,7 +51,6 @@ public:
const string& hostname, const string& hostname,
const string& im_mad_name, const string& im_mad_name,
const string& vmm_mad_name, const string& vmm_mad_name,
const string& vnm_mad_name,
int cluster_id, int cluster_id,
const string& cluster_name, const string& cluster_name,
string& error_str); string& error_str);
@ -273,7 +272,7 @@ private:
*/ */
PoolObjectSQL * create() PoolObjectSQL * create()
{ {
return new Host(-1,"","","","",-1,""); return new Host(-1,"","","",-1,"");
}; };
/** /**

View File

@ -27,54 +27,35 @@ class LibVirtDriver : public VirtualMachineManagerDriver
{ {
public: public:
LibVirtDriver( LibVirtDriver(int userid, const map<string,string> &attrs, bool sudo,
int userid, VirtualMachinePool * pool, const string& emu)
const map<string,string> &attrs, :VirtualMachineManagerDriver(userid, attrs,sudo,pool), emulator(emu)
bool sudo,
VirtualMachinePool * pool,
const string _emulator):
VirtualMachineManagerDriver(userid, attrs,sudo,pool),
emulator(_emulator)
{}; {};
~LibVirtDriver(){}; ~LibVirtDriver(){};
private: private:
static const char * vmware_vnm_name; static const float CGROUP_BASE_CPU_SHARES;
static const float CGROUP_BASE_CPU_SHARES; static const int CEPH_DEFAULT_PORT;
static const int CEPH_DEFAULT_PORT; static const int GLUSTER_DEFAULT_PORT;
static const int GLUSTER_DEFAULT_PORT; static const int ISCSI_DEFAULT_PORT;
static const int ISCSI_DEFAULT_PORT; int deployment_description(const VirtualMachine * vm, const string& fn) const
int deployment_description(
const VirtualMachine * vm,
const string& file_name) const
{ {
int rc = -1; int rc = -1;
if (emulator == "kvm" || emulator == "qemu" ) if (emulator == "kvm" || emulator == "qemu" )
{ {
rc = deployment_description_kvm(vm,file_name); rc = deployment_description_kvm(vm, fn);
}
else if (emulator == "vmware")
{
rc = deployment_description_vmware(vm,file_name);
} }
return rc; return rc;
} }
int deployment_description_kvm( int deployment_description_kvm(const VirtualMachine * v, const string& f) const;
const VirtualMachine * vm,
const string& file_name) const;
int deployment_description_vmware(
const VirtualMachine * vm,
const string& file_name) const;
const string emulator; const string emulator;
}; };

View File

@ -71,7 +71,6 @@ protected:
int hid, int hid,
string& name, string& name,
string& vmm, string& vmm,
string& vnm,
int& cluster_id, int& cluster_id,
string& ds_location, string& ds_location,
bool& is_public_cloud, bool& is_public_cloud,
@ -101,7 +100,6 @@ protected:
int cid, int cid,
const string& hostname, const string& hostname,
const string& vmm_mad, const string& vmm_mad,
const string& vnm_mad,
const string& tm_mad, const string& tm_mad,
const string& ds_location, const string& ds_location,
int ds_id, int ds_id,

View File

@ -536,7 +536,6 @@ public:
int cid, int cid,
const string& hostname, const string& hostname,
const string& vmm_mad, const string& vmm_mad,
const string& vnm_mad,
const string& tm_mad, const string& tm_mad,
const string& ds_location, const string& ds_location,
int ds_id); int ds_id);
@ -595,26 +594,6 @@ public:
return previous_history->vmm_mad_name; return previous_history->vmm_mad_name;
}; };
/**
* Returns the VNM driver name for the current host. The hasHistory()
* function MUST be called before this one.
* @return the VNM mad name
*/
const string & get_vnm_mad() const
{
return history->vnm_mad_name;
};
/**
* Returns the VNM driver name for the previous host. The hasPreviousHistory()
* function MUST be called before this one.
* @return the VNM mad name
*/
const string & get_previous_vnm_mad() const
{
return previous_history->vnm_mad_name;
};
/** /**
* Returns the datastore ID of the system DS for the host. The hasHistory() * Returns the datastore ID of the system DS for the host. The hasHistory()
* function MUST be called before this one. * function MUST be called before this one.

View File

@ -229,9 +229,7 @@ private:
* Function to format a VMM Driver message in the form: * Function to format a VMM Driver message in the form:
* <VMM_DRIVER_ACTION_DATA> * <VMM_DRIVER_ACTION_DATA>
* <HOST> hostname </HOST> * <HOST> hostname </HOST>
* <NET_DRV> net_drv </NET_DRV>
* <MIGR_HOST> m_hostname </MIGR_HOST> * <MIGR_HOST> m_hostname </MIGR_HOST>
* <MIGR_NET_DRV> m_net_drv </MIGR_NET_DRV>
* <DOMAIN> domain_id </DOMAIN> * <DOMAIN> domain_id </DOMAIN>
* <DEPLOYMENT_FILE> dfile </DEPLOYMENT_FILE> * <DEPLOYMENT_FILE> dfile </DEPLOYMENT_FILE>
* <CHECKPOINT_FILE> cfile </CHECKPOINT_FILE> * <CHECKPOINT_FILE> cfile </CHECKPOINT_FILE>
@ -244,9 +242,7 @@ private:
* </VMM_DRIVER_ACTION_DATA> * </VMM_DRIVER_ACTION_DATA>
* *
* @param hostname of the host to perform the action * @param hostname of the host to perform the action
* @param net_drv name of the vlan driver
* @param m_hostname name of the host to migrate the VM * @param m_hostname name of the host to migrate the VM
* @param m_net_drv name of the vlan driver
* @param domain domain id as returned by the hypervisor * @param domain domain id as returned by the hypervisor
* @param dfile deployment file to boot the VM * @param dfile deployment file to boot the VM
* @param cfile checkpoint file to save the VM * @param cfile checkpoint file to save the VM
@ -260,9 +256,7 @@ private:
*/ */
string * format_message( string * format_message(
const string& hostname, const string& hostname,
const string& net_drv,
const string& m_hostname, const string& m_hostname,
const string& m_net_drv,
const string& domain, const string& domain,
const string& ldfile, const string& ldfile,
const string& rdfile, const string& rdfile,

View File

@ -34,11 +34,15 @@ class VirtualNetworkPool : public PoolSQL
{ {
public: public:
VirtualNetworkPool(SqlDB * db, const string& str_mac_prefix, int default_size, VirtualNetworkPool(SqlDB * db,
vector<const SingleAttribute *>& restricted_attrs, const string& str_mac_prefix,
vector<const VectorAttribute *>& hook_mads, const string& remotes_location, int default_size,
const vector<const SingleAttribute *>& _inherit_attrs, vector<const SingleAttribute *>& restricted_attrs,
const VectorAttribute * vlan_conf, const VectorAttribute * vxlan_conf); vector<const VectorAttribute *>& hook_mads,
const string& remotes_location,
const vector<const SingleAttribute *>& _inherit_attrs,
const VectorAttribute * vlan_conf,
const VectorAttribute * vxlan_conf);
~VirtualNetworkPool(){}; ~VirtualNetworkPool(){};

View File

@ -32,7 +32,6 @@ Host::Host(
const string& _hostname, const string& _hostname,
const string& _im_mad_name, const string& _im_mad_name,
const string& _vmm_mad_name, const string& _vmm_mad_name,
const string& _vnm_mad_name,
int _cluster_id, int _cluster_id,
const string& _cluster_name): const string& _cluster_name):
PoolObjectSQL(id,HOST,_hostname,-1,-1,"","",table), PoolObjectSQL(id,HOST,_hostname,-1,-1,"","",table),
@ -40,21 +39,16 @@ Host::Host(
state(INIT), state(INIT),
im_mad_name(_im_mad_name), im_mad_name(_im_mad_name),
vmm_mad_name(_vmm_mad_name), vmm_mad_name(_vmm_mad_name),
vnm_mad_name(_vnm_mad_name),
last_monitored(0), last_monitored(0),
vm_collection("VMS") vm_collection("VMS")
{ {
string default_cpu; //TODO - Get these two from oned.conf
string default_mem;
obj_template = new HostTemplate; obj_template = new HostTemplate;
add_template_attribute("RESERVED_CPU", default_cpu); add_template_attribute("RESERVED_CPU", "");
add_template_attribute("RESERVED_MEM", default_cpu); add_template_attribute("RESERVED_MEM", "");
replace_template_attribute("IM_MAD", im_mad_name); replace_template_attribute("IM_MAD", im_mad_name);
replace_template_attribute("VM_MAD", vmm_mad_name); replace_template_attribute("VM_MAD", vmm_mad_name);
replace_template_attribute("VN_MAD", vnm_mad_name);
} }
Host::~Host() Host::~Host()
@ -594,7 +588,6 @@ string& Host::to_xml(string& xml) const
"<STATE>" << state << "</STATE>" << "<STATE>" << state << "</STATE>" <<
"<IM_MAD>" << one_util::escape_xml(im_mad_name) << "</IM_MAD>" << "<IM_MAD>" << one_util::escape_xml(im_mad_name) << "</IM_MAD>" <<
"<VM_MAD>" << one_util::escape_xml(vmm_mad_name) << "</VM_MAD>" << "<VM_MAD>" << one_util::escape_xml(vmm_mad_name) << "</VM_MAD>" <<
"<VN_MAD>" << one_util::escape_xml(vnm_mad_name) << "</VN_MAD>" <<
"<LAST_MON_TIME>" << last_monitored << "</LAST_MON_TIME>" << "<LAST_MON_TIME>" << last_monitored << "</LAST_MON_TIME>" <<
"<CLUSTER_ID>" << cluster_id << "</CLUSTER_ID>" << "<CLUSTER_ID>" << cluster_id << "</CLUSTER_ID>" <<
"<CLUSTER>" << cluster << "</CLUSTER>" << "<CLUSTER>" << cluster << "</CLUSTER>" <<
@ -628,7 +621,6 @@ int Host::from_xml(const string& xml)
rc += xpath(im_mad_name, "/HOST/IM_MAD", "not_found"); rc += xpath(im_mad_name, "/HOST/IM_MAD", "not_found");
rc += xpath(vmm_mad_name, "/HOST/VM_MAD", "not_found"); rc += xpath(vmm_mad_name, "/HOST/VM_MAD", "not_found");
rc += xpath(vnm_mad_name, "/HOST/VN_MAD", "not_found");
rc += xpath<time_t>(last_monitored, "/HOST/LAST_MON_TIME", 0); rc += xpath<time_t>(last_monitored, "/HOST/LAST_MON_TIME", 0);
@ -688,7 +680,6 @@ int Host::post_update_template(string& error)
string vcenter_password; string vcenter_password;
string new_im_mad; string new_im_mad;
string new_vm_mad; string new_vm_mad;
string new_vn_mad;
get_template_attribute("VCENTER_PASSWORD", vcenter_password); get_template_attribute("VCENTER_PASSWORD", vcenter_password);
@ -718,7 +709,6 @@ int Host::post_update_template(string& error)
get_template_attribute("IM_MAD", new_im_mad); get_template_attribute("IM_MAD", new_im_mad);
get_template_attribute("VM_MAD", new_vm_mad); get_template_attribute("VM_MAD", new_vm_mad);
get_template_attribute("VN_MAD", new_vn_mad);
if (new_im_mad != ""){ if (new_im_mad != ""){
im_mad_name = new_im_mad; im_mad_name = new_im_mad;
@ -728,13 +718,8 @@ int Host::post_update_template(string& error)
vmm_mad_name = new_vm_mad; vmm_mad_name = new_vm_mad;
} }
if (new_im_mad != ""){
vnm_mad_name = new_vn_mad;
}
replace_template_attribute("IM_MAD", im_mad_name); replace_template_attribute("IM_MAD", im_mad_name);
replace_template_attribute("VM_MAD", vmm_mad_name); replace_template_attribute("VM_MAD", vmm_mad_name);
replace_template_attribute("VN_MAD", vnm_mad_name);
return 0; return 0;
}; };

View File

@ -150,7 +150,6 @@ int HostPool::allocate (
const string& hostname, const string& hostname,
const string& im_mad_name, const string& im_mad_name,
const string& vmm_mad_name, const string& vmm_mad_name,
const string& vnm_mad_name,
int cluster_id, int cluster_id,
const string& cluster_name, const string& cluster_name,
string& error_str) string& error_str)
@ -173,11 +172,6 @@ int HostPool::allocate (
goto error_vmm; goto error_vmm;
} }
if ( vnm_mad_name.empty() )
{
goto error_vnm;
}
host = get(hostname,false); host = get(hostname,false);
if ( host !=0) if ( host !=0)
@ -192,7 +186,6 @@ int HostPool::allocate (
hostname, hostname,
im_mad_name, im_mad_name,
vmm_mad_name, vmm_mad_name,
vnm_mad_name,
cluster_id, cluster_id,
cluster_name); cluster_name);
@ -210,10 +203,6 @@ error_vmm:
error_str = "VMM_MAD_NAME cannot be empty."; error_str = "VMM_MAD_NAME cannot be empty.";
goto error_common; goto error_common;
error_vnm:
error_str = "VNM_MAD_NAME cannot be empty.";
goto error_common;
error_duplicated: error_duplicated:
oss << "NAME is already taken by HOST " << host->get_oid() << "."; oss << "NAME is already taken by HOST " << host->get_oid() << ".";
error_str = oss.str(); error_str = oss.str();

View File

@ -631,12 +631,11 @@ int HostAllocate::pool_allocate(
string host = xmlrpc_c::value_string(paramList.getString(1)); string host = xmlrpc_c::value_string(paramList.getString(1));
string im_mad = xmlrpc_c::value_string(paramList.getString(2)); string im_mad = xmlrpc_c::value_string(paramList.getString(2));
string vmm_mad = xmlrpc_c::value_string(paramList.getString(3)); string vmm_mad = xmlrpc_c::value_string(paramList.getString(3));
string vnm_mad = xmlrpc_c::value_string(paramList.getString(4));
HostPool * hpool = static_cast<HostPool *>(pool); HostPool * hpool = static_cast<HostPool *>(pool);
return hpool->allocate(&id, host, im_mad, vmm_mad, vnm_mad, return hpool->allocate(&id, host, im_mad, vmm_mad, cluster_id, cluster_name,
cluster_id, cluster_name, att.resp_msg); att.resp_msg);
} }
/* -------------------------------------------------------------------------- */ /* -------------------------------------------------------------------------- */

View File

@ -321,7 +321,6 @@ int RequestManagerVirtualMachine::get_host_information(
int hid, int hid,
string& name, string& name,
string& vmm, string& vmm,
string& vnm,
int& cluster_id, int& cluster_id,
string& ds_location, string& ds_location,
bool& is_public_cloud, bool& is_public_cloud,
@ -345,7 +344,6 @@ int RequestManagerVirtualMachine::get_host_information(
name = host->get_name(); name = host->get_name();
vmm = host->get_vmm_mad(); vmm = host->get_vmm_mad();
vnm = host->get_vnm_mad();
cluster_id = host->get_cluster_id(); cluster_id = host->get_cluster_id();
@ -439,7 +437,6 @@ int RequestManagerVirtualMachine::add_history(VirtualMachine * vm,
int cid, int cid,
const string& hostname, const string& hostname,
const string& vmm_mad, const string& vmm_mad,
const string& vnm_mad,
const string& tm_mad, const string& tm_mad,
const string& ds_location, const string& ds_location,
int ds_id, int ds_id,
@ -449,8 +446,7 @@ int RequestManagerVirtualMachine::add_history(VirtualMachine * vm,
VirtualMachinePool * vmpool = static_cast<VirtualMachinePool *>(pool); VirtualMachinePool * vmpool = static_cast<VirtualMachinePool *>(pool);
vm->add_history(hid, cid, hostname, vmm_mad, vnm_mad, tm_mad, ds_location, vm->add_history(hid, cid, hostname, vmm_mad, tm_mad, ds_location, ds_id);
ds_id);
if ( vmpool->update_history(vm) != 0 ) if ( vmpool->update_history(vm) != 0 )
{ {
@ -786,7 +782,6 @@ void VirtualMachineDeploy::request_execute(xmlrpc_c::paramList const& paramList,
string hostname; string hostname;
string vmm_mad; string vmm_mad;
string vnm_mad;
int cluster_id; int cluster_id;
string ds_location; string ds_location;
bool is_public_cloud; bool is_public_cloud;
@ -820,7 +815,6 @@ void VirtualMachineDeploy::request_execute(xmlrpc_c::paramList const& paramList,
if (get_host_information(hid, if (get_host_information(hid,
hostname, hostname,
vmm_mad, vmm_mad,
vnm_mad,
cluster_id, cluster_id,
ds_location, ds_location,
is_public_cloud, is_public_cloud,
@ -967,7 +961,6 @@ void VirtualMachineDeploy::request_execute(xmlrpc_c::paramList const& paramList,
cluster_id, cluster_id,
hostname, hostname,
vmm_mad, vmm_mad,
vnm_mad,
tm_mad, tm_mad,
ds_location, ds_location,
ds_id, ds_id,
@ -1023,7 +1016,6 @@ void VirtualMachineMigrate::request_execute(xmlrpc_c::paramList const& paramList
string hostname; string hostname;
string vmm_mad; string vmm_mad;
string vnm_mad;
int cluster_id; int cluster_id;
set<int> ds_cluster_ids; set<int> ds_cluster_ids;
string ds_location; string ds_location;
@ -1066,7 +1058,6 @@ void VirtualMachineMigrate::request_execute(xmlrpc_c::paramList const& paramList
if (get_host_information(hid, if (get_host_information(hid,
hostname, hostname,
vmm_mad, vmm_mad,
vnm_mad,
cluster_id, cluster_id,
ds_location, ds_location,
is_public_cloud, is_public_cloud,
@ -1306,7 +1297,6 @@ void VirtualMachineMigrate::request_execute(xmlrpc_c::paramList const& paramList
cluster_id, cluster_id,
hostname, hostname,
vmm_mad, vmm_mad,
vnm_mad,
tm_mad, tm_mad,
ds_location, ds_location,
ds_id, ds_id,

View File

@ -44,7 +44,6 @@ History::History(
hostname(""), hostname(""),
cid(-1), cid(-1),
vmm_mad_name(""), vmm_mad_name(""),
vnm_mad_name(""),
tm_mad_name(""), tm_mad_name(""),
ds_location(""), ds_location(""),
ds_id(0), ds_id(0),
@ -69,7 +68,6 @@ History::History(
const string& _hostname, const string& _hostname,
int _cid, int _cid,
const string& _vmm, const string& _vmm,
const string& _vnm,
const string& _tmm, const string& _tmm,
const string& _ds_location, const string& _ds_location,
int _ds_id, int _ds_id,
@ -80,7 +78,6 @@ History::History(
hostname(_hostname), hostname(_hostname),
cid(_cid), cid(_cid),
vmm_mad_name(_vmm), vmm_mad_name(_vmm),
vnm_mad_name(_vnm),
tm_mad_name(_tmm), tm_mad_name(_tmm),
ds_location(_ds_location), ds_location(_ds_location),
ds_id(_ds_id), ds_id(_ds_id),
@ -300,26 +297,25 @@ string& History::to_xml(string& xml, bool database) const
oss << oss <<
"<HISTORY>" << "<HISTORY>" <<
"<OID>" << oid << "</OID>" << "<OID>" << oid << "</OID>" <<
"<SEQ>" << seq << "</SEQ>" << "<SEQ>" << seq << "</SEQ>" <<
"<HOSTNAME>" << hostname << "</HOSTNAME>"<< "<HOSTNAME>" << hostname << "</HOSTNAME>"<<
"<HID>" << hid << "</HID>" << "<HID>" << hid << "</HID>" <<
"<CID>" << cid << "</CID>" << "<CID>" << cid << "</CID>" <<
"<STIME>" << stime << "</STIME>" << "<STIME>" << stime << "</STIME>" <<
"<ETIME>" << etime << "</ETIME>" << "<ETIME>" << etime << "</ETIME>" <<
"<VMMMAD>" << one_util::escape_xml(vmm_mad_name) << "</VMMMAD>"<< "<VMMMAD>" << one_util::escape_xml(vmm_mad_name)<<"</VMMMAD>"<<
"<VNMMAD>" << one_util::escape_xml(vnm_mad_name) << "</VNMMAD>"<< "<TMMAD>" << one_util::escape_xml(tm_mad_name) <<"</TMMAD>" <<
"<TMMAD>" << one_util::escape_xml(tm_mad_name) << "</TMMAD>" << "<DS_LOCATION>"<< one_util::escape_xml(ds_location) <<"</DS_LOCATION>"<<
"<DS_LOCATION>" << one_util::escape_xml(ds_location) << "</DS_LOCATION>" << "<DS_ID>" << ds_id << "</DS_ID>" <<
"<DS_ID>" << ds_id << "</DS_ID>" << "<PSTIME>" << prolog_stime << "</PSTIME>"<<
"<PSTIME>" << prolog_stime << "</PSTIME>"<< "<PETIME>" << prolog_etime << "</PETIME>"<<
"<PETIME>" << prolog_etime << "</PETIME>"<< "<RSTIME>" << running_stime << "</RSTIME>"<<
"<RSTIME>" << running_stime << "</RSTIME>"<< "<RETIME>" << running_etime << "</RETIME>"<<
"<RETIME>" << running_etime << "</RETIME>"<< "<ESTIME>" << epilog_stime << "</ESTIME>"<<
"<ESTIME>" << epilog_stime << "</ESTIME>"<< "<EETIME>" << epilog_etime << "</EETIME>"<<
"<EETIME>" << epilog_etime << "</EETIME>"<< "<REASON>" << reason << "</REASON>"<<
"<REASON>" << reason << "</REASON>"<< "<ACTION>" << action << "</ACTION>";
"<ACTION>" << action << "</ACTION>";
if ( database ) if ( database )
{ {
@ -349,7 +345,6 @@ int History::rebuild_attributes()
rc += xpath<time_t>(stime , "/HISTORY/STIME", 0); rc += xpath<time_t>(stime , "/HISTORY/STIME", 0);
rc += xpath<time_t>(etime , "/HISTORY/ETIME", 0); rc += xpath<time_t>(etime , "/HISTORY/ETIME", 0);
rc += xpath(vmm_mad_name , "/HISTORY/VMMMAD", "not_found"); rc += xpath(vmm_mad_name , "/HISTORY/VMMMAD", "not_found");
xpath(vnm_mad_name , "/HISTORY/VNMMAD", "dummy");
rc += xpath(tm_mad_name , "/HISTORY/TMMAD", "not_found"); rc += xpath(tm_mad_name , "/HISTORY/TMMAD", "not_found");
rc += xpath(ds_location , "/HISTORY/DS_LOCATION", "not_found"); rc += xpath(ds_location , "/HISTORY/DS_LOCATION", "not_found");
rc += xpath(ds_id , "/HISTORY/DS_ID", 0); rc += xpath(ds_id , "/HISTORY/DS_ID", 0);

View File

@ -1650,7 +1650,6 @@ void VirtualMachine::add_history(
int cid, int cid,
const string& hostname, const string& hostname,
const string& vmm_mad, const string& vmm_mad,
const string& vnm_mad,
const string& tm_mad, const string& tm_mad,
const string& ds_location, const string& ds_location,
int ds_id) int ds_id)
@ -1672,17 +1671,8 @@ void VirtualMachine::add_history(
to_xml_extended(vm_xml, 0); to_xml_extended(vm_xml, 0);
history = new History(oid, history = new History(oid, seq, hid, hostname, cid, vmm_mad, tm_mad,
seq, ds_location, ds_id, vm_xml);
hid,
hostname,
cid,
vmm_mad,
vnm_mad,
tm_mad,
ds_location,
ds_id,
vm_xml);
history_records.push_back(history); history_records.push_back(history);
}; };
@ -1708,7 +1698,6 @@ void VirtualMachine::cp_history()
history->hostname, history->hostname,
history->cid, history->cid,
history->vmm_mad_name, history->vmm_mad_name,
history->vnm_mad_name,
history->tm_mad_name, history->tm_mad_name,
history->ds_location, history->ds_location,
history->ds_id, history->ds_id,
@ -1741,7 +1730,6 @@ void VirtualMachine::cp_previous_history()
previous_history->hostname, previous_history->hostname,
previous_history->cid, previous_history->cid,
previous_history->vmm_mad_name, previous_history->vmm_mad_name,
previous_history->vnm_mad_name,
previous_history->tm_mad_name, previous_history->tm_mad_name,
previous_history->ds_location, previous_history->ds_location,
previous_history->ds_id, previous_history->ds_id,

View File

@ -161,24 +161,24 @@ int LibVirtDriver::deployment_description_kvm(
vector<const VectorAttribute *> nic; vector<const VectorAttribute *> nic;
string mac = ""; string mac = "";
string bridge = ""; string bridge = "";
string bridge_ovs = ""; string vn_mad = "";
string script = ""; string script = "";
string model = ""; string model = "";
string ip = ""; string ip = "";
string filter = ""; string filter = "";
string default_filter = ""; string default_filter = "";
string default_model = ""; string default_model = "";
const VectorAttribute * graphics; const VectorAttribute * graphics;
string listen = ""; string listen = "";
string port = ""; string port = "";
string passwd = ""; string passwd = "";
string keymap = ""; string keymap = "";
string spice_options = ""; string spice_options = "";
const VectorAttribute * input; const VectorAttribute * input;
@ -834,14 +834,14 @@ int LibVirtDriver::deployment_description_kvm(
for(int i=0; i<num; i++) for(int i=0; i<num; i++)
{ {
bridge = nic[i]->vector_value("BRIDGE"); bridge = nic[i]->vector_value("BRIDGE");
bridge_ovs = nic[i]->vector_value("BRIDGE_OVS"); vn_mad = nic[i]->vector_value("VN_MAD");
mac = nic[i]->vector_value("MAC"); mac = nic[i]->vector_value("MAC");
target = nic[i]->vector_value("TARGET"); target = nic[i]->vector_value("TARGET");
script = nic[i]->vector_value("SCRIPT"); script = nic[i]->vector_value("SCRIPT");
model = nic[i]->vector_value("MODEL"); model = nic[i]->vector_value("MODEL");
ip = nic[i]->vector_value("IP"); ip = nic[i]->vector_value("IP");
filter = nic[i]->vector_value("FILTER"); filter = nic[i]->vector_value("FILTER");
if ( bridge.empty() ) if ( bridge.empty() )
{ {
@ -851,21 +851,14 @@ int LibVirtDriver::deployment_description_kvm(
{ {
file << "\t\t<interface type='bridge'>" << endl; file << "\t\t<interface type='bridge'>" << endl;
string * the_bridge = &bridge;
if ( vm->get_vnm_mad() == "ovswitch" ) if (VirtualNetwork::str_to_driver(vn_mad) == VirtualNetwork::OVSWITCH)
{ {
if ( !bridge_ovs.empty() )
{
the_bridge = &bridge_ovs;
}
file << "\t\t\t<virtualport type='openvswitch'/>" << endl; file << "\t\t\t<virtualport type='openvswitch'/>" << endl;
} }
file << "\t\t\t<source bridge=" file << "\t\t\t<source bridge="
<< one_util::escape_xml_attr(*the_bridge) << "/>\n"; << one_util::escape_xml_attr(bridge) << "/>\n";
} }
if( !mac.empty() ) if( !mac.empty() )

View File

@ -1,494 +0,0 @@
/* -------------------------------------------------------------------------- */
/* Copyright 2002-2015, OpenNebula Project, OpenNebula Systems */
/* */
/* Licensed under the Apache License, Version 2.0 (the "License"); you may */
/* not use this file except in compliance with the License. You may obtain */
/* a copy of the License at */
/* */
/* http://www.apache.org/licenses/LICENSE-2.0 */
/* */
/* Unless required by applicable law or agreed to in writing, software */
/* distributed under the License is distributed on an "AS IS" BASIS, */
/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */
/* See the License for the specific language governing permissions and */
/* limitations under the License. */
/* -------------------------------------------------------------------------- */
#include "LibVirtDriver.h"
#include "Nebula.h"
#include <sstream>
#include <fstream>
#include <libgen.h>
/* ************************************************************************** */
/* LibVirtDriver :: VMware deployment generator */
/* ************************************************************************** */
const char * LibVirtDriver::vmware_vnm_name = "vmware";
int LibVirtDriver::deployment_description_vmware(
const VirtualMachine * vm,
const string& file_name) const
{
ofstream file;
int num;
string vcpu;
string memory;
int memory_in_kb = 0;
const VectorAttribute * os;
string arch = "";
string guestOS = "";
string pciBridge = "";
string boot = "";
vector<string> boots;
const VectorAttribute * features;
vector<const VectorAttribute *> disk;
const VectorAttribute * context;
string type = "";
string target = "";
string ro = "";
string source = "";
string driver = "";
int disk_id;
string default_driver = "";
bool readonly;
vector<const VectorAttribute *> nic;
string network_id = "";
string mac = "";
string bridge = "";
string script = "";
string model = "";
string default_model = "";
const VectorAttribute * graphics;
string listen = "";
string port = "";
string passwd = "";
string keymap = "";
vector<const VectorAttribute *> raw;
string data;
string default_raw;
string data_vmx = "";
ostringstream metadata;
// ------------------------------------------------------------------------
file.open(file_name.c_str(), ios::out);
if (file.fail() == true)
{
goto error_vmware_file;
}
// ------------------------------------------------------------------------
// Starting XML document
// ------------------------------------------------------------------------
file << "<domain type='" << emulator << "'>" << endl;
// ------------------------------------------------------------------------
// Domain name
// ------------------------------------------------------------------------
file << "\t<name>one-" << vm->get_oid() << "</name>" << endl;
// ------------------------------------------------------------------------
// CPU
// ------------------------------------------------------------------------
vm->get_template_attribute("VCPU", vcpu);
if(vcpu.empty())
{
get_default("VCPU", vcpu);
}
if (!vcpu.empty())
{
file << "\t<vcpu>" << vcpu << "</vcpu>" << endl;
}
// ------------------------------------------------------------------------
// Memory
// ------------------------------------------------------------------------
vm->get_template_attribute("MEMORY",memory);
if (!memory.empty())
{
memory_in_kb = atoi(memory.c_str()) * 1024;
file << "\t<memory>" << memory_in_kb << "</memory>" << endl;
}
else
{
goto error_vmware_memory;
}
// ------------------------------------------------------------------------
// OS and boot options
// ------------------------------------------------------------------------
os = vm->get_template_attribute("OS");
if( os != 0 )
{
arch = os->vector_value("ARCH");
guestOS = os->vector_value("GUESTOS");
boot = os->vector_value("BOOT");
}
if ( arch.empty() )
{
get_default("OS","ARCH",arch);
if (arch.empty())
{
goto error_vmware_arch;
}
}
if ( !guestOS.empty() )
{
metadata << "<guestos>" << guestOS << "</guestos>" << endl;
}
if ( boot.empty() )
{
get_default("OS","BOOT",boot);
}
// Start writing to the file with the info we got
file << "\t<os>" << endl;
file << "\t\t<type arch='" << arch << "'>hvm</type>" << endl;
if (!boot.empty())
{
boots = one_util::split(boot, ',');
for (vector<string>::const_iterator it=boots.begin(); it!=boots.end(); it++)
{
file << "\t\t<boot dev='" << *it << "'/>" << endl;
}
}
file << "\t</os>" << endl;
// ------------------------------------------------------------------------
// Features
// ------------------------------------------------------------------------
features = vm->get_template_attribute("FEATURES");
if ( features != 0 )
{
pciBridge = features->vector_value("PCIBRIDGE");
if (!pciBridge.empty())
{
metadata << "<pcibridge>" << pciBridge << "</pcibridge>";
}
}
// ------------------------------------------------------------------------
// Disks
// ------------------------------------------------------------------------
file << "\t<devices>" << endl;
get_default("DISK","DRIVER",default_driver);
num = vm->get_template_attribute("DISK", disk);
for (int i=0; i < num ;i++)
{
type = disk[i]->vector_value("TYPE");
target = disk[i]->vector_value("TARGET");
ro = disk[i]->vector_value("READONLY");
source = disk[i]->vector_value("SOURCE");
driver = disk[i]->vector_value("DRIVER");
disk[i]->vector_value_str("DISK_ID", disk_id);
if (target.empty())
{
goto error_vmware_disk;
}
readonly = false;
if ( !ro.empty() )
{
one_util::toupper(ro);
if ( ro == "YES" )
{
readonly = true;
}
}
one_util::toupper(type);
// ---- Disk type and source for the image ----
if ( type == "BLOCK" )
{
file << "\t\t<disk type='block' device='disk'>" << endl;
file << "\t\t\t<source file='[" << vm->get_ds_id() << "] "
<< vm->get_oid() << "/disk." << disk_id << "'/>" << endl;
}
else if ( type == "CDROM" )
{
file << "\t\t<disk type='file' device='cdrom'>" << endl;
file << "\t\t\t<source file='[" << vm->get_ds_id() << "] "
<< vm->get_oid() << "/disk." << disk_id << ".iso'/>" << endl;
}
else
{
file << "\t\t<disk type='file' device='disk'>" << endl
<< "\t\t\t<source file='[" << vm->get_ds_id() <<"] "
<< vm->get_oid() << "/disk." << disk_id << "/disk.vmdk'/>" << endl;
}
// ---- target device to map the disk ----
file << "\t\t\t<target dev='" << target << "'/>" << endl;
// ---- Image Format using qemu driver ----
if ( !driver.empty() )
{
file << "\t\t\t<driver name='" << driver << "'/>" << endl;
}
else
{
if (!default_driver.empty())
{
file << "\t\t\t<driver name='" <<
default_driver << "'/>" << endl;
}
}
// ---- readonly attribute for the disk ----
if (readonly)
{
file << "\t\t\t<readonly/>" << endl;
}
file << "\t\t</disk>" << endl;
}
// ------------------------------------------------------------------------
// Context Device
// ------------------------------------------------------------------------
context = vm->get_template_attribute("CONTEXT");
if ( context != 0 )
{
target = context->vector_value("TARGET");
context->vector_value_str("DISK_ID", disk_id);
if ( !target.empty() )
{
file << "\t\t<disk type='file' device='cdrom'>" << endl;
file << "\t\t\t<source file='[" << vm->get_ds_id() <<"] "
<< vm->get_oid() << "/disk." << disk_id << ".iso'/>" << endl;
file << "\t\t\t<target dev='" << target << "'/>" << endl;
file << "\t\t\t<readonly/>" << endl;
file << "\t\t</disk>" << endl;
}
else
{
vm->log("VMM", Log::WARNING, "Could not find target device to"
" attach context, will continue without it.");
}
}
// ------------------------------------------------------------------------
// Network interfaces
// ------------------------------------------------------------------------
get_default("NIC", "MODEL", default_model);
num = vm->get_template_attribute("NIC", nic);
for(int i=0; i<num; i++)
{
network_id = nic[i]->vector_value("NETWORK_ID");
mac = nic[i]->vector_value("MAC");
target = nic[i]->vector_value("TARGET");
script = nic[i]->vector_value("SCRIPT");
model = nic[i]->vector_value("MODEL");
if (vm->get_vnm_mad() == LibVirtDriver::vmware_vnm_name)
{
bridge = "one-pg-";
bridge.append(network_id);
}
else
{
bridge = nic[i]->vector_value("BRIDGE");
}
file << "\t\t<interface type='bridge'>" << endl;
file << "\t\t\t<source bridge='" << bridge << "'/>" << endl;
if( !mac.empty() )
{
file << "\t\t\t<mac address='" << mac << "'/>" << endl;
}
if( !target.empty() )
{
file << "\t\t\t<target dev='" << target << "'/>" << endl;
}
if( !script.empty() )
{
file << "\t\t\t<script path='" << script << "'/>" << endl;
}
string * the_model = 0;
if (!model.empty())
{
the_model = &model;
}
else if (!default_model.empty())
{
the_model = &default_model;
}
if (the_model != 0)
{
file << "\t\t\t<model type='" << *the_model << "'/>" << endl;
}
file << "\t\t</interface>" << endl;
}
// ------------------------------------------------------------------------
// Graphics
// ------------------------------------------------------------------------
graphics = vm->get_template_attribute("GRAPHICS");
if ( graphics != 0 )
{
type = graphics->vector_value("TYPE");
listen = graphics->vector_value("LISTEN");
port = graphics->vector_value("PORT");
passwd = graphics->vector_value("PASSWD");
keymap = graphics->vector_value("KEYMAP");
if ( type == "vnc" || type == "VNC" )
{
file << "\t\t<graphics type='vnc'";
if ( !listen.empty() )
{
file << " listen='" << listen << "'";
}
if ( !port.empty() )
{
file << " port='" << port << "'";
}
if ( !passwd.empty() )
{
file << " passwd='" << passwd << "'";
}
if ( !keymap.empty() )
{
file << " keymap='" << keymap << "'";
}
file << "/>" << endl;
}
else
{
vm->log("VMM", Log::WARNING,
"Not supported graphics type, ignored.");
}
}
file << "\t</devices>" << endl;
// ------------------------------------------------------------------------
// Raw VMware attributes
// ------------------------------------------------------------------------
num = vm->get_template_attribute("RAW", raw);
for(int i=0; i<num;i++)
{
type = raw[i]->vector_value("TYPE");
one_util::toupper(type);
if ( type == "VMWARE" )
{
data = raw[i]->vector_value("DATA");
file << "\t" << data << endl;
data_vmx = raw[i]->vector_value("DATA_VMX");
if ( !data_vmx.empty() )
{
metadata << "<datavmx>" << data_vmx << "</datavmx>";
}
}
}
get_default("RAW", default_raw);
if ( !default_raw.empty() )
{
file << "\t" << default_raw << endl;
}
if ( !metadata.str().empty() )
{
file << "\t<metadata>" << metadata.str() << "</metadata>" << endl;
}
file << "</domain>" << endl;
file.close();
return 0;
error_vmware_file:
vm->log("VMM", Log::ERROR, "Could not open VMWARE deployment file.");
return -1;
error_vmware_arch:
vm->log("VMM", Log::ERROR, "No ARCH defined and no default provided.");
file.close();
return -1;
error_vmware_memory:
vm->log("VMM", Log::ERROR, "No MEMORY defined and no default provided.");
file.close();
return -1;
error_vmware_disk:
vm->log("VMM", Log::ERROR, "Wrong target value in DISK.");
file.close();
return -1;
}

View File

@ -26,7 +26,6 @@ source_files=[
'VirtualMachineManagerDriver.cc', 'VirtualMachineManagerDriver.cc',
'XenDriver.cc', 'XenDriver.cc',
'LibVirtDriverKVM.cc', 'LibVirtDriverKVM.cc',
'LibVirtDriverVMware.cc',
'XMLDriver.cc' 'XMLDriver.cc'
] ]

View File

@ -347,9 +347,7 @@ void VirtualMachineManager::do_action(const string &action, void * arg)
string * VirtualMachineManager::format_message( string * VirtualMachineManager::format_message(
const string& hostname, const string& hostname,
const string& net_drv,
const string& m_hostname, const string& m_hostname,
const string& m_net_drv,
const string& domain, const string& domain,
const string& ldfile, const string& ldfile,
const string& rdfile, const string& rdfile,
@ -373,17 +371,15 @@ string * VirtualMachineManager::format_message(
} }
oss << "<VMM_DRIVER_ACTION_DATA>" oss << "<VMM_DRIVER_ACTION_DATA>"
<< "<HOST>" << hostname << "</HOST>" << "<HOST>" << hostname << "</HOST>";
<< "<NET_DRV>" << net_drv << "</NET_DRV>";
if (!m_hostname.empty()) if (!m_hostname.empty())
{ {
oss << "<MIGR_HOST>" << m_hostname << "</MIGR_HOST>" oss << "<MIGR_HOST>" << m_hostname << "</MIGR_HOST>";
<< "<MIGR_NET_DRV>"<< m_net_drv << "</MIGR_NET_DRV>";
} }
else else
{ {
oss << "<MIGR_HOST/><MIGR_NET_DRV/>"; oss << "<MIGR_HOST/>";
} }
if (!domain.empty()) if (!domain.empty())
@ -571,8 +567,6 @@ void VirtualMachineManager::deploy_action(int vid)
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
"", "",
vm->get_deployment_file(), vm->get_deployment_file(),
@ -629,7 +623,7 @@ void VirtualMachineManager::save_action(
VirtualMachine * vm; VirtualMachine * vm;
const VirtualMachineManagerDriver * vmd; const VirtualMachineManagerDriver * vmd;
string hostname, vnm_mad, checkpoint_file; string hostname, checkpoint_file;
string vm_tmpl; string vm_tmpl;
string * drv_msg; string * drv_msg;
int ds_id; int ds_id;
@ -666,14 +660,12 @@ void VirtualMachineManager::save_action(
} }
hostname = vm->get_previous_hostname(); hostname = vm->get_previous_hostname();
vnm_mad = vm->get_previous_vnm_mad();
checkpoint_file = vm->get_previous_checkpoint_file(); checkpoint_file = vm->get_previous_checkpoint_file();
ds_id = vm->get_previous_ds_id(); ds_id = vm->get_previous_ds_id();
} }
else else
{ {
hostname = vm->get_hostname(); hostname = vm->get_hostname();
vnm_mad = vm->get_vnm_mad();
checkpoint_file = vm->get_checkpoint_file(); checkpoint_file = vm->get_checkpoint_file();
ds_id = vm->get_ds_id(); ds_id = vm->get_ds_id();
} }
@ -681,8 +673,6 @@ void VirtualMachineManager::save_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
hostname, hostname,
vnm_mad,
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -762,8 +752,6 @@ void VirtualMachineManager::shutdown_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -839,8 +827,6 @@ void VirtualMachineManager::reboot_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -911,8 +897,6 @@ void VirtualMachineManager::reset_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -984,8 +968,6 @@ void VirtualMachineManager::cancel_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1062,8 +1044,6 @@ void VirtualMachineManager::cancel_previous_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_previous_hostname(), vm->get_previous_hostname(),
vm->get_previous_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1111,7 +1091,6 @@ void VirtualMachineManager::cleanup_action(
string tm_command = ""; string tm_command = "";
string m_hostname = ""; string m_hostname = "";
string m_net_drv = "";
const VirtualMachineManagerDriver * vmd; const VirtualMachineManagerDriver * vmd;
@ -1141,7 +1120,6 @@ void VirtualMachineManager::cleanup_action(
if ( cancel_previous && vm->hasPreviousHistory() ) if ( cancel_previous && vm->hasPreviousHistory() )
{ {
m_hostname = vm->get_previous_hostname(); m_hostname = vm->get_previous_hostname();
m_net_drv = vm->get_previous_vnm_mad();
} }
if (!vm->get_host_is_cloud()) if (!vm->get_host_is_cloud())
@ -1157,9 +1135,7 @@ void VirtualMachineManager::cleanup_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
m_hostname, m_hostname,
m_net_drv,
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
"", "",
@ -1245,8 +1221,6 @@ void VirtualMachineManager::cleanup_previous_action(int vid)
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_previous_hostname(), vm->get_previous_hostname(),
vm->get_previous_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1330,9 +1304,7 @@ void VirtualMachineManager::migrate_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_previous_hostname(), vm->get_previous_hostname(),
vm->get_previous_vnm_mad(),
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
"", "",
@ -1439,8 +1411,6 @@ void VirtualMachineManager::restore_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1521,8 +1491,6 @@ void VirtualMachineManager::poll_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1696,8 +1664,6 @@ void VirtualMachineManager::timer_action()
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1814,8 +1780,6 @@ void VirtualMachineManager::attach_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -1936,8 +1900,6 @@ void VirtualMachineManager::detach_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2020,8 +1982,6 @@ void VirtualMachineManager::snapshot_create_action(int vid)
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2100,8 +2060,6 @@ void VirtualMachineManager::snapshot_revert_action(int vid)
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2180,8 +2138,6 @@ void VirtualMachineManager::snapshot_delete_action(int vid)
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2291,8 +2247,6 @@ void VirtualMachineManager::disk_snapshot_create_action(int vid)
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2405,8 +2359,6 @@ void VirtualMachineManager::attach_nic_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2491,8 +2443,6 @@ void VirtualMachineManager::detach_nic_action(
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",
@ -2560,8 +2510,6 @@ int VirtualMachineManager::updatesg(VirtualMachine * vm, int sgid)
// Invoke driver method // Invoke driver method
drv_msg = format_message( drv_msg = format_message(
vm->get_hostname(), vm->get_hostname(),
vm->get_vnm_mad(),
"",
"", "",
vm->get_deploy_id(), vm->get_deploy_id(),
"", "",