openEuler 20.03
Disabling the Firewall and SELinux
- Open the /etc/selinux/config file and change SELINUX=enforcing to SELINUX=disabled.
- Stop and disable the firewall:
1 2
systemctl stop firewalld.service systemctl disable firewalld.service
Configuring Huge Pages and Enabling IOMMU
- Check whether huge pages have been developed.
1cat /proc/meminfo |grep -i huge
If the values of HugePages_Total and Hugepagesize are greater than 0, huge pages have been configured and do not need to be configured again. Ensure that the size of a huge page is greater than 5 GB. Otherwise, go to step 2.
- (Optional) Modify the startup settings and edit the /boot/efi/EFI/openEuler/grub.cfg file.
1vi /boot/efi/EFI/openEuler/grub.cfg
- In startup item menuentry, add huge page items and perform the following configuration:
default_hugepagesz=512M hugepagesz=512M hugepages=128 iommu.passthrough=1

- Modify the /etc/fstab file to mount huge pages upon system startup.
1vim /etc/fstab
Add the following content to the file:
1nodev /mnt/huge hugetlbfs defaults 0 0
- Create an /mnt/huge directory.
1mkdir -p /mnt/huge
- Restart the server for huge pages to take effect.
- Enable SMMU.
Restart the server, go to the BIOS, and check that SMMU is enabled.


- In startup item menuentry, add huge page items and perform the following configuration:
Configuring the Yum Source
- Mount an image.
1 2
mkdir -p /mnt/repo mount -o loop /home/software/openEuler-20.03-LTS-everything-aarch64-dvd.iso /mnt/repo/
- Configure the Yum source.
1 2 3 4
cd /etc/yum.repos.d mkdir backup mv *.repo backup vim /etc/yum.repos.d/local.repoAdd the following content to the file:[local] name=local baseurl=file:///mnt/repo enable=1 gpgcheck=0 priority=1 [arch_fedora_online] name=arch_fedora baseurl=https://mirrors.huaweicloud.com/fedora/releases/30/Everything/aarch64/os/ enabled=1 gpgcheck=0 priority=2
- Make the Yum source configuration take effect.
1yum clean all&&yum makecache
Installing Dependencies
- Install the dependencies.
yum install -y numactl numactl-devel openssl-devel libcap-ng-devel qemu-guest-agent qemu* libvirt* traceroute iperf3 virt-install AAVMF python2-paramiko
Some of the preceding software packages need to be downloaded from the Internet. Ensure that the server is connected to the Internet and the corresponding sources are configured.
- Modify the /etc/libvirt/qemu.conf file.Change the current commands:
#user = "root" #group = "root"
To:
user = "root" group = "root"
- Restart the libvirt service.
systemctl restart libvirtd
Parent topic: Configuring the Compilation Environment