Testing the Video Stream Cloud Phone Density
- Extract the cfct_config file from the DemoVideoEngine.tar.gz package.
1 2 3
cd /home/kbox_video/ tar -xvf DemoVideoEngine.tar.gz cfct_config chmod 644 cfct_config
- Check BIOS configuration parameters and the GPU working mode. For details, see Configuring the BIOS and Configuring the GPU Working Mode.
- Use the BMC to adjust the server fan speed percentage to 100%.
- Log in to the BMC over SSH.
1ssh {BMC_user_name}@{BMC_IP_address}
- Set the fan speed adjustment mode to manual.
1ipmcset -d fanmode -v 1 0
The command output is as follows:
1 2 3
Set fan mode successfully. Current Mode: manual Time out : 100000000 seconds
- Set the fan speed percentage to 100%.
1ipmcset -d fanlevel -v 100
The command output is as follows:
1 2 3
Set fan level successfully. Current Mode: manual, timeout 100000000 seconds. Global Manual Fan Level: 100%
- Query the fan status.
1ipmcget -d faninfo
The command output is as follows:
1 2 3
Current Mode: manual, timeout 100000000 seconds. Manual fan level: Fan1: 100, Fan2: 100, Fan3: 100, Fan4: 100
- Log in to the BMC over SSH.
- Bind the GPU driver processes to idle cores. For details about how to bind NIC interrupts to idle cores, see "Binding NICs to CPUs" in the Kbox Cloud Phone Container Feature Guide.
- Query the GPU process ID.
1ps -ef |grep gfx
The command output is as follows:1 2
root 1703 2 1 Aug31 ? 07:31:36 [gfx_0.0.0] root 1739 2 1 Aug31 ? 09:13:08 [gfx_0.0.0]
- Bind the first GPU process to an idle core.
1taskset -pc 32-33 1703
The command output is as follows:1 2
pid 1703's current affinity list: 0-127 pid 1703's new affinity list: 32,33
- Bind the second GPU process to an idle core.
1taskset -pc 64-65 1739
The command output is as follows:1 2
pid 1739's current affinity list: 0-127 pid 1739's new affinity list: 64,65
If four GPU driver processes are displayed, bind the first two driver processes to cores 32 to 33 and the last two driver processes to cores 64 to 65.
- Query the GPU process ID.
- Scatter single-queue NIC interrupts. For a single-queue NIC, the RPS service can be used to distribute interrupts to multiple cores. This prevents performance bottlenecks caused by a large number of software interrupts centralized to a single core. The method is as follows. NIC enp125s0f1 is used as an example. The following commands bind the NIC interrupts to the first eight CPU cores and tune other RPS settings to optimize the NIC performance in this scenario.
1 2 3 4 5
systemctl stop irqbalance.service systemctl disable irqbalance.service echo ff000000 > /sys/class/net/enp125s0f1/queues/rx-0/rps_cpus echo 4096 > /sys/class/net/enp125s0f1/queues/rx-0/rps_flow_cnt echo 32768 > /proc/sys/net/core/rps_sock_flow_entries
- Disable NUMA balancing and SWAP.
1 2
echo 0 > /proc/sys/kernel/numa_balancing swapoff -a
- Set the CPU_BIND_MODE field in the cfct_config file to the value in Table 1 (1 indicates binding NUMA).
Table 1 Mapping between test specifications and CPU_BIND_MODE Test Specifications
CPU_BIND_MODE
7260 processor + W6600, 60 channels (higher density), high-quality image of the Genshin Impact login page, 1080p@30 fps
1
If the 7260 processor + W6600 density test in Table 1 is performed, ensure that Modifying the W6600 Density Test Configuration has been performed.
- When using the cfct_video script to start multiple containers, decide the number of containers to be started based on Table 1 in 7. The following uses 60 as an example. Run the following commands in sequence.
To test the high-quality image of the Genshin Impact login page, you need to log in to the game account and set the parameters. To perform a multi-channel test, log in to the game for one channel, set the image quality, and log out. Refer to Creating a Base Data Volume and create a base data volume to ensure that the image quality of the containers started later are consistent.
- Start the cloud phone.
1./cfct_video start 1 60
- Open the Genshin Impact game.
1./cfct_video start_ygame 1 60
- Screen capture.
1./cfct_video screencap 1 60
After screen capture is complete, download the screenshots to the local host. If all screenshots are game screens of Genshin Impact, as shown in the following figure, the app is successfully started.

- Start the cloud phone.
- Test the performance after the client is connected to the server.
- Decompress the pressure test tool VideoClientEmulator.tar.gz on the local host or another server.
1 2
tar -xvpf VideoClientEmulator.tar.gz cd VideoClientEmulator
- Modify the core binding mode in the config file of the pressure test tool. If the test is performed on the local host, allocate and bind the tool to idle cores. The following is a configuration example:
# CPU allocated to the pressure test tool CPU_FOR_CLIENT=("32" "96" "33" "97") CPU_FOR_SERVER="64" CPU_FOR_CMD="65" - Run the following command to connect to the server.If the test is performed on the local host, the IP address can be 127.0.0.1. An example command is as follows. The parameters that follow ./test.sh connect are the server IP address, start port number, and end port number, respectively.
1./test.sh connect 127.0.0.1 8001 8060
Check whether the number of clients displayed in the output is correct. For example:1 2
[INFO] checking current client num ... [INFO] current client process num: =60
- Run the following command to display and collect frame rate data.The following command is an example. The parameters that follow ./test.sh start are the server IP address, start port number, end port number, and collection time, respectively.
1./test.sh start 127.0.0.1 8001 8060 900
After the 15-minute countdown, an analysis report of the frame rate data is generated, as shown in the following figure. A CSV file that records single-channel data is generated in the test directory.

- Decompress the pressure test tool VideoClientEmulator.tar.gz on the local host or another server.
- Collect data.
- Obtain the native_perf_tools_20230830.tar.gz package by referring to Video Stream Engine, decompress it, and go to the native_perf_tools folder.
- The native perf tools depend on the nmon tool. If the nmon tool is not installed, run apt to install it.
1apt install nmon
- Run the following commands in sequence to collect data for 15 minutes. {prefix_number} is the prefix of the folder for storing collected data.
1 2
source env.sh ./native_get_perf_data.sh all {prefix_number}

- After the collection is complete, download the following files to the local host, parse the files, and generate test reports.
- log folder in the native_perf_tools folder on the server, which contains performance data of the server, such as performance data of CPUs, GPUs, and encoding cards.
- The client.log file in the /sdcard/log directory on the mobile phone client is the client log file, including information about the decoding frame rate and network lag.
- Place the preceding files and folders in the same path, for example, D:\tmp.Download ExtractingData_20230310.tar.gz and decompress it. Go to the ExtractingData folder and run the following command:
python parse.py D:\tmp
An output folder is generated in D:\tmp, which contains tables and images.