- 论坛徽章:
- 0
|
已经搞定
如果用的是xen下创建的虚拟机
root@lab auto]# ln -s /etc/xen/rhel54 /etc/xen/auto/rhel54
[root@lab auto]# ls -l
總計 4
lrwxrwxrwx 1 root root 15 4月 15 23:12 rhel54 -> /etc/xen/rhel54
[root@lab auto]# pwd
/etc/xen/auto
# 手工啟動 rhel54 的設定檔案
[root@lab xen]# /etc/init.d/xendomains restart
Shutting down Xen domains:Restoring Xen domains: rhel54.
Starting auto Xen domains: rhel54(skip)[root@lab xen]#
# 預設開機啟動 xendomains 服務
[root@lab xen]# chkconfig xendomains on
如果先用的内核是kvm
28.1. Automtically starting guests
This section covers how to make virtualized guests start automatically during the host system's boot phase.
This example uses virsh to set a guest, TestServer, to automatically start when the host boots.
# virsh autostart TestServer
Domain TestServer marked as autostarted
The guest now automatically starts with the host.
To stop a guest automatically booting use the --disable parameter
# virsh autostart --disable TestServer
Domain TestServer unmarked as autostarted
The guest no longer automatically starts with the host. |
|