安装KVM后,我们通过SecureCRT管理virt-manager
首先在KVM本机执行:
编辑sshd_config: # vi /etc/ssh/sshd_config #Match User anoncvs X11Forwarding yes # AllowTcpForwarding no
安装相关组件
#yum install -y xorg-x11-font-utils.x86_64 xorg-x11-server-utils.x86_64 xorg-x11-utils.x86_64 xorg-x11-xauth.x86_64 xorg-x11-xinit.x86_64
在SecureCRT机子上安装Xming
Xming 的SourceForge 页面:http://sourceforge.NET/projects/xming/
这里下载到Xming-6-9-0-31-setup.exe,双击安装至完成, 运行Xming:
设置SecureCRT转发
SecureCRT-->“连接”-->“属性”:
在弹出的对话框中,勾中“连接” “端口转发”“远程/X11”的“转发X11数据包”, 点确定
完成以下基本就可以了。
报错汇总:
# virt-manager
Unable to initialize GTK: could not open display
确保有安装xorg-x11-xauth
#yum -y install xorg-x11-xauth
退出xshell后从新登录,然后再调用virt-manager即可。
# virt-manager
process 2827: D-Bus library appears to be incorrectly set up; failed to read machine uuid: Failed to open "/var/lib/dbus/machine-id": No such file or directory
See the manual page for dbus-uuidgen to correct this issue.
D-Bus not built with -rdynamic so unable to print a backtrace
确保libvirtd开启状态:
# /etc/init.d/libvirtd status libvirtd is stopped # /etc/init.d/libvirtd start
如果问题依旧,按以下方法处理:
# mkdir -p /var/lib/dbus # dbus-uuidgen > /var/lib/dbus/machine-id # virt-manager
virt-manager出现乱码,解决:
#yum install -y dejavu-lgc-sans-fonts #virt-manager