Symptoms

A customer tries to enable the CPU autoscaling feature for the PACI service, but the following error message appears:

For CPU autoscaling to work, restart must be allowed.

Cause

The ability to use autoscaling depends on the settings of the Instance Manager (IM) service.

These can be found at the PACI IM server in the /usr/local/share/PACI-im/IM-config.xml file. The parameters can-decrease-when-started for CPU and RAM that define the Autoscale behavior are listed below:

<ve-reconfig>
<VM>
<linux>
...
<ram can-decrease-when-started="false" can-increase-when-started="true"/>   <--- parameter can-increase-when-started has to be "true"
...
<cpu can-change-when-started="true" />   <--- This value has to be "true" <--- <--- parameter can-increase-when-started has to be "true"
</linux>
<windows>
...
<ram can-decrease-when-started="false" can-increase-when-started="true"/>
...
<cpu can-change-when-started="true" />   <--- This value has to be "true"
</windows>
</VM>
<CT>
<linux>
...
<ram can-change-when-started="true" />   <--- Changed from "false" to "true"
...
<cpu can-change-when-started="true" />   <--- Changed from "false" to "true"
</linux>
<windows>
...
<ram can-change-when-started="true" />   <--- Changed from "false" to "true"
...
<cpu can-change-when-started="true" />   <--- Changed from "false" to "true"
</windows>
</CT>
</ve-reconfig>

We see separate sections for Windows and Linux Virtual Machines and containers. The XML tags <cpu> and <ram> must have the true value for the parameters listed above. This will allow the Autoscale feature to be enabled from the Operations Automation Customer Control Panel.

The same settings allow CPU and RAM re-sizing for running virtual environments.

Currently, PACI does not allow you to decrease the RAM amount for Virtual Machines. This is why the XML-tag <ram> for VMs has the following form:

<ram can-decrease-when-started="false" can-increase-when-started="true"/>

Resolution

Perform the following on PACI IM server:

  1. Set the parameters in the /usr/local/share/PACI-im/IM-config.xml file described above to true.

  2. Restart the PACI IM service:

    # service PACI-im stop
    # service terracotta stop
    # service terracotta start
    # service PACI-im start
    

    Starting with POA 5.5.6, it is possible to issue a fast IM restart that does not interrupt background operations like backups creation:

    # service PACI-im fast-restart
    

    Note: During execution of fast-restart PACI Control Panel will be not accessible in PCP/CCP.

Internal content

Link on internal Article