Rate This Document
Findability
Accuracy
Completeness
Readability

Enabling Hugepage Memory

  1. Add hugepage configurations to the kernel boot parameters. Taking 1 GB hugepages as an example: default_hugepagesz=1G hugepagesz=1G hugepages=64.

    default_hugepagesz and hugepagesz indicate the hugepage granularity. The 2 MB hugepage granularity is also supported. hugepages indicates the number of hugepages.

  2. Based on the basic configuration in Startup with libvirt, add a configuration to the cvm.xml file to enable static hugepages.
    1. Enable the hugepage memory function: <launchSecurity type='cca' hisi-cca-enable='yes'/>

    2. Configure the backend memory and set the attribute to shared.

    Destroying a large-memory cVM may take a long time. After the destroy command is executed, the VM status may remain as in shutdown instead of the expected status shut off. In this case, you need to re-run the destroy command (for example, re-run virsh destroy cvm).