## 4 Solution for MCRC Problem
### VM Selection
For the overloaded type of \(h_{j}\), we select as few VMs as possible to migrate, so that the values of \(\textbf{A}_{j,l}\), \(\textbf{B}_{j,l}\), \(\textbf{C}_{j,l}\), and \(\textbf{D}_{j,l}\) are all less than or equal to 1. For example, if the overloaded type of \(h_{i}\) is \((\textbf{DA})\), then the VMs with the workload type \((\textbf{DA}**)\) should be selected for migration as much as possible. Therefore, we need to use \((\textbf{DA})\) as the reference to sort the VMs on \(h_{i}\). Given marks \(\textbf{A}^{\prime}\), \(\textbf{B}^{\prime}\), \(\textbf{C}^{\prime}\), and \(\textbf{D}^{\prime}\), the corresponding values of host \(h_{i}\) and VM \(v_{j}\) in \(t_{l}\) are \(V(\textbf{A}_{i,l}^{\prime})=r_{i,l}^{cpu}-TH_{up}^{cpu}\times c_{i}^{cpu}\), \(V(\textbf{B}_{i,l}^{\prime})=r_{i,l}^{num}-TH_{up}^{mem}\times c_{i}^{mem}\), \(V(\textbf{C}_{i,l}^{\prime})=r_{i,l}^{disk}-TH_{up}^{disk}\times c_{i}^{disk}\), \(V(\textbf{D}_{i,l}^{\prime})=r_{i,l}^{int}-TH_{up}^{turb}\times c_{i}^{net}\), \(V(\textbf{A}_{j,l}^{\prime})=s_{j,l}^{cpu}\), \(V(\textbf{B}_{j,l}^{\prime})=s_{j,l}^{mem}\), \(V(\textbf{C}_{j,l}^{\prime})=s_{j,l}^{disk}\), and \(V(\textbf{D}_{j,l}^{\prime})=s_{j,l}^{net}\). Given the overloaded reference \(RF=(\textbf{E}_{1}\cdots\textbf{E}_{p})\), where \(\textbf{E}_{g}\in\{\textbf{A}^{\prime},\textbf{B}^{\prime},\textbf{C}^{\prime}, \textbf{D}^{\prime}\}\), and the sort of \(\textbf{E}_{1}\cdots\textbf{E}_{p}\) corresponds to that of \(ol\_type_{j,l}\). The resources usage of \(v_{j}\) based on \(RF\) is denoted as \(RU_{j}=(\textbf{e}_{j,1}\cdots\textbf{e}_{j,p})\), where \(\textbf{e}_{j,g}\in\{\textbf{A}^{\prime},\textbf{B}^{\prime},\textbf{C}^{\prime}, \textbf{D}^{\prime}\}\) and the sort of \(\textbf{e}_{j,1}\cdots\textbf{e}_{j,p}\) also corresponds to that of \(ol\_type_{j,l}\). Regarding two different VMs \(v_{j}\) and \(v_{j}\), if \(v_{j}\) is better than \(v_{j^{\prime}}\) based on \(RF\), denoted as \(v_{j}>v_{j^{\prime}}\), then the following is met:  
\[\prod_{g=1}^{p}\alpha_{S}^{RF}\times|V(\textbf{E}_{g})-V(\textbf{e}_{j,g})|>\prod _{g=1}^{p}\alpha_{S}^{RF}\times|V(\textbf{E}_{g})-V(\textbf{e}_{j^{\prime},g})|, \tag{51}\]  
where \(\alpha_{S}^{RF}\) is the overloaded reference weight. Resources with higher overloaded levels should be prioritized to reduce load; hence the value of the corresponding \(\alpha_{S}^{RF}\) should be larger. We let the value of \(\alpha_{S}^{RF}\) be equal to the value of resource mark in \(wl\_type_{j,l}\) that corresponds to the \(\textbf{E}_{g}\) of the same subscript \(g\). For instance, assuming \(wl\_type_{j,l}=(\textbf{C}_{j,l}\textbf{A}_{j,l})\), then \(RF=(\textbf{E}_{1}\textbf{E}_{2})=(\textbf{C}_{j,l}^{\prime}\textbf{A}_{j,l}^{ \prime})\), \(\alpha_{1}^{RF}=V(\textbf{C}_{j,l})\), and \(\alpha_{2}^{RF}=V(\textbf{A}_{j,l})\). If \(v_{j}\) is equivalent to \(v_{j^{\prime}}\) based on \(RF\), denoted as \(v_{j}=v_{j^{\prime}}\), then the following is met:  
\[\prod_{g=1}^{p}\alpha_{S}^{RF}\times|V(\textbf{E}_{g})-V(\textbf{e}_{j,g})|= \prod_{g=1}^{p}\alpha_{S}^{RF}\times|V(\textbf{E}_{g})-V(\textbf{e}_{j^{\prime},g})|. \tag{52}\]If \(v_{j}\) is worse than \(v_{j^{\prime}}\) based on \(RF\), denoted as \(v_{j}<v_{j^{\prime}}\), then the following is met:  
\[\prod_{g=1}^{p}\alpha_{g}^{RF}\times|V(\mathbf{E}_{g})-V(\mathbf{e}_{j,g})|< \prod_{g=1}^{p}\alpha_{g}^{RF}\times|V(\mathbf{E}_{g})-V(\mathbf{e}_{j^{\prime},g})|. \tag{53}\]  
According to the above given relationship between VMs based on \(RF\), we sort the VMs on \(h_{i}\) from _'good'_ to _'bad'_ as an ordered list. Subsequently, the VMs are sequentially selected from the ordered list and placed in the list of VM to be migrated. After each selection, we determine whether \(h_{i}\) is still overloaded after removing the resources required by the selected VM. If it is overloaded, continue to select VMs in order; otherwise, stop VM selection.