VMware Training from VMTraining
Partner LoginPartner Login
   Home   Search Login Register  
May 18, 2012, 01:52:17 AM
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Learn VMware View 4 in a THREE day course! Click here for more details about our View 4 class.
 
Pages: [1]   Go Down
  Print  
Author Topic: Starting and stopping VM's from the command line  (Read 2709 times)
Viperman
Global Moderator
Jr. Member
*****
Offline Offline

Posts: 57


« on: May 07, 2008, 12:30:22 AM »

Power Options on a VM
Note
• If you use trysoft, the Guest OS will be shutdown gracefully.
• The trysoft is a “mode” option – it tries to run the normal scripts but uses
a hard shutdown/startup if the VM is not behaving properly.
• There are two other “modes” – soft which runs scripts but never does a
hard start or stop or “hard” which powers off/on a VM as if you had hit the
power switch. Sometimes people use trysoft first, and then if the VM
refuses to power of, they follow it with hard power off

1. To start a virtual machine type:
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx start
trysoft

2. To stop a virtual machine type:
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx stop
trysoft

3. To suspend a virtual machine type:
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx
suspend

Note:
There isn’t much in the way of status/progress here. The old-style
“Remote Console” from ESX 2.x days used to give you dialog box with a
status bar

4. To reset a virtual machine type
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx reset
trysoft
Note:
This a soft reboot of the virtual machine

5. To find out the Power Status of a VM use:
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx
getstate
Note:
It will return “On”; “Off”; “Suspend” and “Stuck” if the VM is waiting for
interaction

Finding the Heartbeat
1. Type:
vmware-cmd /vmfs/volumes/<UUID>/instructor1/instructor1.vmx
getheartbeat
Note:
You should see a number. Repeat the command. If the number increments
the machine is alive. It stays the same it is dead. It doesn’t have a heart
beat!
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

  Powered by SMF 1.1.10 | SMF © 2006-2009, Simple Machines LLC  

VMware Training, Global Locations

VMTraining is a division of Global Training Solutions, Inc.
© GLOBAL TRAINING SOLUTIONS, INC. 2007 - 2012

Contact us at (815) 313-4472 or Sales@VMTraining.net

To report technical problems,
please email webmaster@vmtraining.net