File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -31,9 +31,14 @@ install_nemu() {
3131 ;;
3232 esac
3333
34+ local virtiofs_bin=" virtiofsd-${arch} "
35+
3436 curl -LO " ${nemu_repo} /releases/download/${nemu_version} /${nemu_bin} "
37+ curl -LO " ${nemu_repo} /releases/download/${nemu_version} /${virtiofs_bin} "
38+
3539 sudo install -o root -g root -m 0755 " ${nemu_bin} " " /usr/local/bin"
36- rm -rf " ${nemu_bin} "
40+ sudo install -o root -g root -m 0755 " ${virtiofs_bin} " " /usr/local/bin"
41+ rm -rf " ${nemu_bin} " " ${virtiofs_bin} "
3742}
3843
3944install_firmware () {
Original file line number Diff line number Diff line change @@ -121,3 +121,14 @@ if [ "$KATA_EXPERIMENTAL_FEATURES" = true ]; then
121121 feature=" newstore"
122122 sudo sed -i -e " s|^experimental.*$|experimental=[ \" $feature \" ]|" " ${runtime_config_path} "
123123fi
124+
125+ # Enable virtiofs if VIRTIO_FS is set to true
126+ # currently we use nemu for virtiofs testing
127+ if [ " $VIRTIO_FS " = true ] && [ " $KATA_HYPERVISOR " = " nemu" ]; then
128+ echo " Configure virtio-fs on kata-runtime config file"
129+ sudo crudini --set " $runtime_config_path " hypervisor.qemu virtio_fs_daemon " \" /usr/local/bin/virtiofsd-${arch} \" "
130+ sudo crudini --set " $runtime_config_path " hypervisor.qemu shared_fs " \" virtio-fs\" "
131+ sudo crudini --set " $runtime_config_path " hypervisor.qemu enable_hugepages " true"
132+
133+ sudo sysctl -w vm.nr_hugepages=1024
134+ fi
You can’t perform that action at this time.
0 commit comments