
누구든지 KVM 게스트에 대해 지연된 시작을 도입해야 할 수 있는 포인터를 찾고 있습니다. 즉, 각 가상 서버를 시작하는 사이에 30초가 소요됩니다. 즉, 모든 가상 서버를 한 번에 시작하는 대신 디스크가 충돌하고 실제로 모든 것을 해결하는 데 훨씬 더 오랜 시간이 걸립니다.
내가 시도한 접근 방식은 다음과 같이 /etc/sysconfig/libvirt-guests를 업데이트하는 것입니다.
# URIs to check for running guests
# example: URIS='default xen:/// vbox+tcp://host/system lxc:///'
#URIS=default
# action taken on host boot
# - start all guests which were running on shutdown are started on boot
# regardless on their autostart settings
# - ignore libvirt-guests init script won't start any guest on boot, however,
# guests marked as autostart will still be automatically started by
# libvirtd
ON_BOOT=ignore
# Number of seconds to wait between each guest start. Set to 0 to allow
# parallel startup.
START_DELAY=180
# action taken on host shutdown
# - suspend all running guests are suspended using virsh managedsave
# - shutdown all running guests are asked to shutdown. Please be careful with
# this settings since there is no way to distinguish between a
# guest which is stuck or ignores shutdown requests and a guest
# which just needs a long time to shutdown. When setting
# ON_SHUTDOWN=shutdown, you must also set SHUTDOWN_TIMEOUT to a
# value suitable for your guests.
ON_SHUTDOWN=shutdown
# If set to non-zero, shutdown will suspend guests concurrently. Number of
# guests on shutdown at any time will not exceed number set in this variable.
#PARALLEL_SHUTDOWN=0
# Number of seconds we're willing to wait for a guest to shut down. If parallel
# shutdown is enabled, this timeout applies as a timeout for shutting down all
# guests on a single URI defined in the variable URIS. If this is 0, then there
# is no time out (use with caution, as guests might not respond to a shutdown
# request). The default value is 300 seconds (5 minutes).
#SHUTDOWN_TIMEOUT=300
# If non-zero, try to bypass the file system cache when saving and
# restoring guests, even though this may give slower operation for
# some file systems.
#BYPASS_CACHE=0
libvirt.conf의 기본 URI 경로도 올바른지 확인했으며 위 구성 파일의 기본값을 qemu:///system & qemu:///로 변경해 보았습니다.
변경 사항에 관계없이 모든 게스트가 동시에 부팅됩니다.
또한 심볼릭 링크가 libvirt-guests 구성을 재정의하는 경우를 대비하여 /etc/libvirt/qemu/autostart/의 내용을 제거하려고 시도했지만 아무 것도 시작되지 않습니다(놀랍지 않습니다).
누구든지 이 작업을 수행했거나 대체 방법이 있습니까?
스크립트 내에서 지연을 도입하기 위해 에뮬레이터 경로를 리디렉션할 수 있다는 것을 알고 있습니다. 그러나 이는 옵션이 아닌 새 게스트 생성에 영향을 미칠 수 있습니다.
감사해요.