首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往
您找到你想要的搜索结果了吗?
是的
没有找到

xen 基本操作命令

虚拟机的组成部分 1.虚拟机配置文件 [root@localhost ~]# ls /etc/xen/ auto               scripts                              xend-pci-quirks.sxp      xmexample.hvm qemu-ifup      xend-config.sxp                xmexample1               xmexample.vti rhel5u8-1      xend-pci-permissive.sxp      xmexample2 2.储存虚拟机的介质 [root@localhost ~]# ls /var/lib/xen/p_w_picpaths/ rhel5u8-1.img #虚拟机的基本管理命令:查看、启动、关闭 使用xm查看虚拟机 [root@localhost ~]# xm list Name                                      ID Mem(MiB) VCPUs State   Time(s) Domain-0                                   0     3490     2 r-----    533.8 Domain-0 系统必须安装创建、管理、删除虚拟域的工具。它们包括 xm 和 xend 程序和服务。 尽量减少在 Domain-0 中运行程序和服务,Domain-0 中 CPU 的使用率直接影响其他虚拟域 CPU 资源的分配。 #使用xm启动虚拟机 [root@localhost ~]# xm create rhel5u8-1 Using config file "/etc/xen/rhel5u8-1". Started domain rhel5u8-1 [root@localhost ~]# xm list Name                                      ID Mem(MiB) VCPUs State   Time(s) Domain-0                                   0     3490     2 r-----    535.2 rhel5u8-1                                  2      520     1 r-----      3.7 #使用xm关闭虚拟机 [root@localhost ~]# xm shutdown 2 #使用virsh查看虚拟机 [root@localhost ~]# virsh list Id Name                 State ----------------------------------  0 Domain-0             running #使用virsh启动虚拟机 [root@localhost ~]# virsh start rhel5u8-1 Domain rhel5u8-1 started [root@localhost ~]# virsh list Id Name                 State ----------------------------------  0 Domain-0             running  3 rhel5u8-1            running #使用virsh关闭虚拟机 [root@localhost ~]# virsh shutdown rhel5u8-1 Domain rhel5u8-1 is being shutdown

02

使用supervisor监控管理Linux服务进程

Supervisor Docs 使用ssh远程维护VPS时候,要在后台挂起一个程序。挂起程序很简单,在command后加上&符号就可以,但是当断开ssh时候,挂起的程序也随之killed, 很是恼火。在使用nohup 的时候意外发现了supervisor, supervisor使用python开发,通过配置文件来配置需要启动监管的程序,作为supervisord的子进程。执行程序supervisord即‘守护进程’(Daemon)[在希腊神话中是守护神的意思!类似中国的护法?daemon这个词和恶魔(demon)只差一个字母,且发音完全一样!多的a这个品质可理解为全神关注的(absorbed)/精确的(accurate)/能干的(able)/乐于助人的(accommodating)/友好的(amicable)]。类似httpd, mysqld最后的d字母意为守护程序。

01
领券