configure: Readline: no
configure: Python: yes
configure: DTrace: no
configure: numad: no
configure: XML Catalog: /etc/xml/catalog
configure: Init script: check
configure: Char device locks: /var/lock
configure:
configure: Privileges
configure:
configure: QEMU: root:root
configure:
编译:make
安装:make install
libvirtd安装成功!
为了保证后面能够顺利安装VM,首先我们重启服务器:
reboot
第四步: 使用virt-install命令新建虚拟机
重新登录服务器:
首先将虚拟机系统的安装镜像拷贝到主目录下:
scp ubuntu-11.10-server-amd64.iso root@idea05.acis.ufl.edu:~
在后台启动libvirt进程:
libvirtd -d
从下面输出可以看到libvirtd进程已经在后台启动:
root 1348 0.5 0.0 232260 5592 ? Sl 18:10 0:00 /usr/sbin/libvirtd -d
nobody 1747 0.0 0.0 26080 964 ? S 18:10 0:00 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/default.conf
root 2388 0.0 0.0 13632 960 pts/2 S+ 18:11 0:00 grep --color=auto libvirt
然后执行virt-install新建虚拟机:
virt-install --connect qemu:///system -n vm1 -r 512 --vcpus=2 --disk path=/var/lib/libvirt/images/vm1.img,size=12 -c ubuntu-11.10-server-amd64.iso --vnc --noautoconsole --os-type linux --accelerate --hvm
Starting install...
Allocating 'vm1.img' | 12 GB 00:00
Creating domain... | 0 B 00:00
Domain installation still in progress. You can reconnect to
the console to complete the installation process.
Starting install...
Allocating 'vm2.img' | 12 GB 00:00
Creating domain... | 0 B 00:00
Domain installation still in progress. You can reconnect to
the console to complete the installation process.
第五步: 在本地通过virt-manager连接远程服务器上的VM
在本地电脑安装virt-manager
apt-get install virt-manager
安装之后,在终端切换到root用户,输入virt-manager命令来启动