cloudstack-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CLOUDSTACK-10232) SystemVMs and VR to run as HVM on XenServer
Date Thu, 22 Feb 2018 16:51:00 GMT

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-10232?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16373060#comment-16373060
] 

ASF GitHub Bot commented on CLOUDSTACK-10232:
---------------------------------------------

khos2ow commented on a change in pull request #2465: CLOUDSTACK-10232: SystemVMs and VR to
run as HVM on XenServer
URL: https://github.com/apache/cloudstack/pull/2465#discussion_r170022564
 
 

 ##########
 File path: plugins/hypervisors/xenserver/src/com/cloud/hypervisor/xenserver/resource/CitrixResourceBase.java
 ##########
 @@ -1368,12 +1368,23 @@ public VM createVmFromTemplate(final Connection conn, final VirtualMachineTO
vmS
 
         final String bootArgs = vmSpec.getBootArgs();
         if (bootArgs != null && bootArgs.length() > 0) {
+            // send boot args for PV instances
             String pvargs = vm.getPVArgs(conn);
             pvargs = pvargs + vmSpec.getBootArgs().replaceAll(" ", "%");
             if (s_logger.isDebugEnabled()) {
                 s_logger.debug("PV args are " + pvargs);
             }
             vm.setPVArgs(conn, pvargs);
+
+            // send boot args into xenstore-data for HVM instances
+            Map<String, String> xenstoreData = new HashMap<>();
+
+            xenstoreData.put("vm-data/cloudstack/init", bootArgs);
+            vm.setXenstoreData(conn, xenstoreData);
+
+            if (s_logger.isDebugEnabled()) {
+                s_logger.debug("HVM args are " + bootArgs);
 
 Review comment:
   Technically it can be removed, but as its javadoc says: `This function is intended to lessen
the computational cost of disabled log debug statements.` and the fact that they are used
all over the place I added the same if block.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> SystemVMs and VR to run as HVM on XenServer
> -------------------------------------------
>
>                 Key: CLOUDSTACK-10232
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-10232
>             Project: CloudStack
>          Issue Type: New Feature
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: SystemVM, Virtual Router, XenServer
>    Affects Versions: 4.10.0.0, 4.9.3.0
>            Reporter: Pierre-Luc Dion
>            Priority: Major
>
> Following the recent Meltdown-Spectre security risk,one of the mitigation,as of Jan 2018,
for XenServer Hypervisor is to run Virtual-Machine in HVM mode.
> Currently SystemVMs and Virtual-Routers run as PV on XenServer and the eth0 is configured
using {{/etc/init.d/cloud-early-config}} using grub params from {{/proc/cmdline}}. When VM
run as HVM, it is not possible to push initial boot instruction via pygrub.
> Quick tests has been done using xenstore and it look like it would be possible to send
same initial boot instruction has pygrub but using xenstore for HVM instances.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message