我正在尝试使用 KVM 在 Ubuntu Server 18.04.1 主机上安装 Ubuntu Server 18.04.1 客户机。我已将 ubuntu-18.04.1-live-server-amd64.iso 下载到主机。
当我运行以下命令时:
sudo virt-install -n marmoset-eugo-1 --description "Eng Undergrad Office Marmoset server" \
--os-type=Linux --os-variant=ubuntu18.04 --ram=4096 --vcpus=6 \
--disk path=/var/lib/libvirt/images/marmoset-eugo-1.img,bus=virtio,size=128,format=qcow2 \
--network bridge:br0 --graphics none \
--location /home/d24lau/Downloads/ubuntu-18.04.1-live-server-amd64.iso \
--extra-args console=ttyS0
我收到以下错误:
Starting install...
Retrieving file .treeinfo... | 0 B 00:00:00
Retrieving file content... | 0 B 00:00:00
Retrieving file info... | 77 B 00:00:00
ERROR Couldn't find hvm kernel for Ubuntu tree.
Domain installation does not appear to have been successful.
If it was, you can restart your domain by running:
virsh --connect qemu:///system start marmoset-eugo-1
otherwise, please restart your installation.
因此我尝试使用 CDROM 选项:
sudo virt-install -n marmoset-eugo-1 --description "Eng Undergrad Office Marmoset server" \
--os-type=Linux --os-variant=ubuntu18.04 --ram=4096 --vcpus=6 \
--disk path=/var/lib/libvirt/images/marmoset-eugo-1.img,bus=virtio,size=128,format=qcow2 \
--network bridge:br0 --graphics none \
--cdrom /home/d24lau/Downloads/ubuntu-18.04.1-live-server-amd64.iso
此时,安装似乎已开始,但我似乎无法与安装进行交互。我收到以下输出,并且终端无限期等待:
WARNING CDROM media does not print to the text console by default, so you likely will not see text install output. You might want to use --location. See the man page for examples of using --location with CDROM media
Starting install...
Allocating 'marmoset-eugo-1.img' | 128 GB 00:00:00
Connected to domain marmoset-eugo-1
Escape character is ^]
有人曾经进行过这种类型的安装吗?我尝试从 CLI 执行所有操作,而我能找到的唯一视频教程是通过图形 KVM 虚拟管理器执行此操作的。
谢谢,