본문 바로가기

Engineering/__00. Virtual OS

vshpere guest os 강제 종료 등 관리

1. GUI 등으로 Guest OS 를 종료할 수 없을 때 명령어로 실행

    # esxcli vm process list (현재 로딩된 Guest OS 를 확인한다.)

    # esxcli vm process kill --type=hard --world-id=123456

[root@localhost:~]  esxcli vm process kill
Error: Missing required parameter -w|--world-id
       Missing required parameter -t|--type

Usage: esxcli vm process kill [cmd options]

Description: 
  kill                  Used to forcibly kill Virtual Machines that are stuck and not responding to normal stop operations.

Cmd options:
  -t|--type=<str>       The type of kill operation to attempt. There are three types of VM kills that can be attempted:   [soft, hard, force]. Users
                        should always attempt 'soft' kills first, which will give the VMX process a chance to shutdown cleanly (like kill or kill
                        -SIGTERM). If that does not work move to 'hard' kills which will shutdown the process immediately (like kill -9 or kill
                        -SIGKILL). 'force' should be used as a last resort attempt to kill the VM. If all three fail then a reboot is required.
                        (required)
  -w|--world-id=<long>  The World ID of the Virtual Machine to kill. This can be obtained from the 'vm process list' command (required)