CentOS之Xen操作

1.Xen管理工具xm:

列出所有正在运行的虚拟操作系统:[root@localhost ~]# /usr/sbin/xm list

调整虚拟平台/虚拟操作系统的占用内存:[root@localhost ~]# /usr/sbin/xm mem-set

关闭被虚拟的系统:[root@localhost ~]# /usr/sbin/xm shutdown

调整虚拟平台及虚拟操作系统的虚拟CPU个数:[root@localhost ~]# /usr/sbin/xm vcpu-set

查看虚拟系统运行的状态:[root@localhost ~]# xm top[root@localhost ~]# xentop

通过配置文件来引导被虚拟的操作系统:[root@localhost ~]# /usr/sbin/xm create -c 虚拟操作系统的启动配置文件,比如我们要启动被虚拟的操作系统Fedora 的配置文件是 fc5vm.cfg,就可以通过下面的命令来引导 Fedora[root@localhost ~]# /usr/sbin/xm create -c fc5vm.cfg 。

2.Xen 的相关文件存放位置:

内核及xen自身存放于/boot;内核模块存放于/lib/modules;xen 的配置文件及守护程序的存放位置,一般的情况下,Xen 的配置文件存放于/etc/xen目录。

可执行命令存放于/usr/sbin,[root@localhost ~]#ls /usr/sbin/xm

Xen 的服务器 xend 和 xendomains 启动脚本,一般是位于 /etc/init.d/ 目录中,也就是/etc/init.d/xend;/etc/init.d/xend 负责启动 xend 服务器。xend 服务器的启动 / 停止 / 重启 / 状态查询,请用下面的命令:

[root@localhost ~]# /etc/init.d/xend start (启动 xend ,如果 xend 没有运行)

[root@localhost ~]# /etc/init.d/xend stop (停止 xend ,如果 xend 正在运行)

[root@localhost ~]# /etc/init.d/xend restart (重启正在运行的 xend)

[root@localhost ~]# /etc/init.d/xend status (查看 xend 状态)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章