Jump to content
Welcome to our new Citrix community!
  • 0

How do you restart a VM via command line


Josh Christian

Question

I'm not sure what caused it, but a VM hung during a Shutdown. I tried to shutdown and Force Shutdown, and after a few minutes, most of the options disappeared leaving only the option to change home server, and view properties of the VM.

How do I get the VM to power back up? Is there a method of reboot from the command line?

Thanks,
~Josh

Link to comment

12 answers to this question

Recommended Posts

  • 0

I get the error Multiple matches found when running the vm-reboot, and vm-reset-power, Does that give any clues as to what caused the error? Is it save to run the vm-reset-powerstate? The vm-reboot, and vm-resume commands seem to have hung, they ran for more than 20 minutes each without anything changeing.

Thanks,
~Josh

Link to comment
  • 0

I went ahead and tried it, got a new error:

[root@DENXEN02 ~]# /opt/xensource/bin/xe vm-reset-powerstate vm=DENDC04 --force
The operation could not be performed because a domain still exists for the specified VM.
vm: c4c0ed90-70b6-ab28-363f-de69c34579dd (DENDC04)
domid: 289

Is the domain referring to the HA that is/was setup on the pool? I believe setting up the HA was the initial cause of the issue, as that was the project I was working on today before this happend?

Thanks,
~Josh

Link to comment
  • 0

[root@DENXEN02 ~]# /opt/xensource/bin/list_domains
id | uuid | state
0 | a0743a85-54d1-49b3-89e1-b60b813d0e78 | R
221 | 85f715c1-515d-b020-bb21-b107eb83c343 | B H
224 | d440f1d2-0bac-8b67-bf55-e3293a0e192c | RH
225 | bc35f600-b21b-4f1a-64a1-d88636fb3cfa | B H
226 | 6976ed04-f7d2-3d99-4624-eeb19ae1de5e | B H
227 | 1889259d-56bf-2bec-1f9a-252f7e1792e8 | B H
228 | 6538f4ab-29ac-901d-724f-17b79bfe1257 | B H
234 | 3f4f20fb-6c81-e233-90ba-47631f218696 | B H
235 | 8b3cecfb-5026-5638-1f3c-db1f642408c0 | B H
276 | c53931b7-018b-00f9-6344-2ac6d6fd9bc2 | B H
278 | 66dc1fd2-db1c-0a42-8d01-b14c1c47e3e1 | B H
281 | 77e45002-bfd1-c330-681e-6c3caf2247c8 | B H
289 | c4c0ed90-70b6-ab28-363f-de69c34579dd | S H
302 | c3c12f16-017d-fd10-12a1-3c3315da95ea | P H
303 | 9ed14ca6-cfa6-c630-b626-63792c9ec518 | B H

I hope you can translate.... All I know is c4c0ed90-70b6-ab28-363f-de69c34579dd is the uuid for the crashed VM.

Thanks,
~Josh

Link to comment
  • 0

Hi, we're having the same problem. All the hosts that can't have their powerstate reset, or be shutdown reside on one host in the pool but we're getting the same error as Josh when we try to reset-powerstate:

The operation could not be performed because a domain still exists for the specified VM.

Is there a solution to this as I'd rather not have to forcibly reboot the host.

Thanks,

--
Toby

Link to comment
  • 0

Right, we rebooted the host in the end and that seemed to fix the problem. It also fixed the problem of some VMs in the pool that refused to start because "reason: Failed to lock all VBDs" so I assume the two issues may have been related.

It would be interesting to know any other approach that we could take if this happens in the future.

Thank you,

--
Toby

Link to comment
  • 0

Toby,

I'm currious if you guys were experementing or have implemented HA? We disabled HA after the reboot, and suddenly the system instability (power states resetting) was removed. In the end, the forced shutdown was the only way we could remedy the situation as well. This issue is still unanswered as to a good way to fix the issue.

I believe this has something to do with the HA function interfearing with the regular computing process. I've found some posts hinting that its because i have semi-dissimilar hardware.

I'm hoping 5.5 will fix the issue.

~Josh

Link to comment
  • 0

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...