## 4 Solution for MCRC Problem
### VM Placement
```
1:hostlist, vmlist
2:allocation of the VMs
3:\(HG\leftarrow\) get_HG(hostlist)
4:for each \(W\_{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ }}}}}}}}}}}}}}}\) \(H\)do
5:\(W\_{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{ \mathit{ }}}}}}}}}}}}}}}}}}\) \(H\)do
6:\(W\_{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{ \mathit{ \mathit{ }}}}}}}}}}}}}}}}}}}\) \(H\)do
7:\(cwlt\_VM\_List\_sorted_{y}\leftarrow\) get_sorted(\(cwlt\_VM\_List_{i}\))
8:endfor
9:for each \(W\_{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{ \mathitmathit{ \mathitmathitmathitmathitmathitmathitmathitmathit {    \mathit{    }}}}}}}}}}}}}}}\) \(H\)do
10:\(cwlt\_VM\_List\_sorted_{y}\)
11:endfor
12:for each \(W\_{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{ \mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathit{\mathitmathit{\mathitmathitmathitmathitmathitmathitmathitmathitmathit {   \mathitmathitmathitmathitmathitmathitmathitmathit{    \mathit{ \mathitmathitmathitmathitmathitmathitmathitmathitmathit{   \mathitmathitmathitmathitmathitmathitmathit{   \mathitmathitmathitmathitmathitmathitmathit{ \mathitmathitmathitmathitmathitmathitmathit{ \mathitmathitmathitmathitmathitmathit{ \mathitmathitmathitmathitmathitmathitmathitmathitmathitmathitmathit\mathitmathit{ \mathitmathitmathitmathitmathitmathit \mathitmathit{ \mathitmathitmathitmathitmathitmathitmathit{ \mathitmathitmathitmathitmathitmathit{ \mathitmathitmathitmathitmathitmathitmathit{After all the above operations are completed, if there are still some VMs not migrated, perform the following steps:

1. [label=(Step 1)]
2. [label=(Step 2)]
3. [label=(Step 3)]
4. Implementing the TSCP algorithm again but skipping the steps of VM grouping and sorting;
5. [label=(Step 2)]
6. If there are still some VMs not migrated, implement the First-Fit VM placement algorithm for these VMs;
7. If there are still some VMs not migrated, it indicates that the resources of all working hosts are not enough, and the energy-saving mode hosts should be boosted up. After this, we perform underloaded host detection. If there are underloaded hosts, then we leverage the TSCP algorithm to place all the VMs on them. ## 5 Performance Evaluation

In this section, we evaluate the performance of our proposed solution with a real VM workload trace-driven simulation. ### Experiment Setup

Based on the energy consumption analysis and statistics of each component of the host in the data center by [PERSON] et al. [51] and [PERSON] et al. [52], we simulated three sizes of large, medium, and small hosts: \(H_{large}\), \(H_{medium}\), and \(H_{small}\), respectively. Their resource parameters are shown in Table 1, and their power parameters are shown in Table 2. We simulated a CDC consisting of 200 \(H_{small}\) hosts, 100 \(H_{medium}\) hosts, and 50 \(H_{large}\) hosts. The VM workload trace dataset is provided by the Alibaba CDC [49]. The dataset contains workload traces of 4000 VMs over 8 consecutive days. The traces in the record are generated by sampling every five minutes. Each trace records the CPU usage, memory usage, disk I/O, and network throughput of a VM at a sampling moment. We selected the traces of 1000 VMs in one day (a total of 288 time segments) from the dataset to simulate the users' business demands for VMs. The simulation is implemented on the CDC simulator CloudMatrix Lite [53], and the CAE-based filter and the ARP algorithm is based on PyTorch [54]. We set the electricity price as \(EP=0.25\$/\mathrm{kWh}\), the SLAV penalty is a static price \(pun_{cpu}=pun_{mem}=pun_{disk}=pun_{net}=0.01\$\).