Last active
November 5, 2024 11:30
-
-
Save yen3/884bf14ec8286df35de67953a561eee8 to your computer and use it in GitHub Desktop.
aarch64 virt-install commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
rm -rf /home/yen3/ubuntu.qcow2 | |
qemu-img create -f qcow2 /home/yen3/ubuntu.qcow2 10G | |
virsh undefine ubuntu1604arm64 --nvram | |
install_from_localtion() { | |
virt-install -n ubuntu1604arm64 --memory 1024 --arch aarch64 --vcpus 1 \ | |
--disk /home/yen3/ubuntu.qcow2,device=disk,bus=virtio \ | |
--os-type=linux \ | |
--nographic \ | |
--boot uefi \ | |
--location 'http://ports.ubuntu.com/dists/xenial/main/installer-arm64/' | |
} | |
install_from_iso_vga_fedora() { | |
virt-install -n ubuntu1604arm64 --memory 2048 --arch aarch64 --vcpus 4 \ | |
--disk /home/yen3/ubuntu.qcow2,device=disk,bus=virtio \ | |
--os-type=generic \ | |
--boot uefi \ | |
--video vga \ | |
--graphics vnc,port=5999 \ | |
--noautoconsole \ | |
--noreboot \ | |
--network bridge=docker0 \ | |
--cdrom /home/yen3/Downloads/Fedora-Server-dvd-aarch64-27-1.6.iso | |
#--cdrom /home/yen3/Downloads/mini_arm64.iso | |
} | |
install_from_iso_vga_debian() { | |
# Fail, install through console | |
virt-install -n ubuntu1604arm64 --memory 2048 --arch aarch64 --vcpus 4 \ | |
--disk /home/yen3/ubuntu.qcow2,device=disk,bus=virtio \ | |
--os-type=generic \ | |
--graphics vnc,port=5999 \ | |
--noreboot \ | |
--cdrom /home/yen3/Downloads/debian-testing-arm64-xfce-CD-1.iso | |
} | |
install_from_iso_vga_centos() { | |
# Fail, install through console | |
virt-install -n ubuntu1604arm64 --memory 2048 --arch aarch64 --vcpus 4 \ | |
--disk /home/yen3/ubuntu.qcow2,device=disk,bus=virtio \ | |
--os-type=generic \ | |
--boot uefi \ | |
--graphics vnc,port=5999 \ | |
--noreboot \ | |
--cdrom /home/yen3/Downloads/CentOS-7-aarch64-Everything.iso | |
#--cdrom /home/yen3/Downloads/CentOS-7-aarch64-NetInstall.iso | |
} | |
#install_from_localtion | |
#install_from_iso_vga_debian | |
#install_from_iso_vga_centos | |
install_from_iso_vga_fedora |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
virsh undefine centos-aarch64 --nvram || true | |
virt-install -n centos-aarch64 --memory 2048 --arch aarch64 --vcpus 4 \ | |
--disk /share/Public/import_test/centos.qcow2,device=disk,bus=virtio \ | |
--os-type=generic \ | |
--video vga \ | |
--boot uefi \ | |
--graphics vnc,port=5999 \ | |
--noautoconsole \ | |
--noreboot \ | |
--network bridge=br0 \ | |
--import \ | |
--boot loader=/usr/share/AAVMF/QEMU_EFI-pflash.raw,loader_ro=yes,loader_type=pflash,nvram=/share/Public/import_test/centos_VARS.fd | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ubuntu 18.04 | |
sudo apt install -y qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils virt-manager | |
sudo apt install -y qemu-system-common qemu-efi-aarch64 qemu-system-arm | |
qemu-system-common qemu-efi-aarch64 libosinfo-bin -y |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, i got a problem.
How to disable Secure Boot for aarch64, install VM with virt-install.