mirror of https://github.com/apache/cloudstack.git
set the cpu weight based on cpu * cores
This commit is contained in:
parent
57ff1d650f
commit
e60f356f62
|
|
@ -120,6 +120,10 @@ public class KVMGuestOsMapper {
|
|||
s_mapper.put("Windows 95", "Windows 95");
|
||||
s_mapper.put("Windows NT 4", "Windows NT");
|
||||
s_mapper.put("Windows 3.1", "Windows 3.1");
|
||||
s_mapper.put("Windows PV", "Other PV");
|
||||
s_mapper.put("Other PV (32-bit)", "Other PV");
|
||||
s_mapper.put("Other PV (64-bit)", "Other PV");
|
||||
|
||||
}
|
||||
|
||||
public static String getGuestOsName(String guestOsName) {
|
||||
|
|
|
|||
|
|
@ -2301,7 +2301,7 @@ public class LibvirtComputingResource extends ServerResourceBase implements Serv
|
|||
|
||||
s_logger.debug("starting " + vmName + ": " + vm.toString());
|
||||
startDomain(conn, vmName, vm.toString());
|
||||
|
||||
Script.runSimpleBashScript("virsh schedinfo " + vmName + " --set cpu_shares=" + vmSpec.getCpus() * vmSpec.getSpeed());
|
||||
|
||||
NicTO[] nics = vmSpec.getNics();
|
||||
for (NicTO nic : nics) {
|
||||
|
|
|
|||
|
|
@ -188,6 +188,7 @@ INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (156, 10,
|
|||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (157, 10, 'Ubuntu 10.10 (64-bit)');
|
||||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (158, 9, 'Sun Solaris 11 (64-bit)');
|
||||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (159, 9, 'Sun Solaris 11 (32-bit)');
|
||||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (160, 6, 'Windows PV');
|
||||
|
||||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (200, 1, 'Other CentOS (32-bit)');
|
||||
INSERT INTO `cloud`.`guest_os` (id, category_id, display_name) VALUES (201, 1, 'Other CentOS (64-bit)');
|
||||
|
|
|
|||
Loading…
Reference in New Issue