maas does not know about VM "paused" state
Bug #1394382 reported by
Mike McCracken
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
Critical
|
Julian Edwards |
Bug Description
If an enlisted VM with power type "Virsh" is paused for any reason, this triggers an internal server error, traceable back to virsh.py line 245, which shows that power_state_virsh only knows about 'off' or 'on'.
This looks like it happened to us when the machine that the VM (on an orange box) was running on ran out of disk. The VM got paused, and then maas crashed trying to show us the node info.
Related branches
lp:~julian-edwards/maas/vm-pause-state-bug-1394382
- Graham Binns (community): Approve
-
Diff: 41 lines (+22/-5)1 file modifiedsrc/provisioningserver/drivers/hardware/virsh.py (+22/-5)
lp:~andreserl/maas/backport_rev_3397_lp1394382
- Andres Rodriguez (community): Approve
-
Diff: 41 lines (+22/-5)1 file modifiedsrc/provisioningserver/drivers/hardware/virsh.py (+22/-5)
Changed in maas: | |
status: | New → Triaged |
importance: | Undecided → Critical |
milestone: | none → 1.7.1 |
tags: | added: power |
Changed in maas: | |
assignee: | nobody → Julian Edwards (julian-edwards) |
status: | Triaged → In Progress |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Thanks for looking at this. Here's some info that might be useful when
adding support for other states to virsh.py:
libvirt's docs are incomplete, so looking through the source, domstate can
return these states:
(this is line 132 in tools/virsh- domain- monitor. c) IMPL(vshDomainS tate,
VIR_DOMAIN_ LAST,
N_("no state"),
N_("running" ),
N_("idle" ),
N_("paused" ),
N_("in shutdown"),
N_("shut off"),
N_("crashed" ),
N_("pmsuspended "))
VIR_ENUM_
Note that domstate also has a --reason flag that "also prints the reason
for the state", and it will print it like this:
"paused (reason)"
Also note that if domstate returns paused "due to io error" (which you'll
know because of the --reason flag), run domblkerror to get info:
(from a manpage or something in the source:)
=item B<domblkerror> I<domain>
Show errors on block devices. This command usually comes handy when
B<domstate> command says that a domain was paused due to I/O error.
The B<domblkerror> command lists all block devices in error state and
the error seen on each of them.
On Wed, Nov 19, 2014 at 4:45 PM, Julian Edwards <email address hidden>
wrote:
> ** Changed in: maas /bugs.launchpad .net/bugs/ 1394382 /bugs.launchpad .net/maas/ +bug/1394382/ +subscriptions
> Status: New => Triaged
>
> ** Changed in: maas
> Importance: Undecided => Critical
>
> ** Changed in: maas
> Milestone: None => 1.7.1
>
> ** Tags added: power
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https:/
>
> Title:
> maas does not know about VM "paused" state
>
> Status in MAAS:
> Triaged
>
> Bug description:
> If an enlisted VM with power type "Virsh" is paused for any reason,
> this triggers an internal server error, traceable back to virsh.py
> line 245, which shows that power_state_virsh only knows about 'off' or
> 'on'.
>
> This looks like it happened to us when the machine that the VM (on an
> orange box) was running on ran out of disk. The VM got paused, and
> then maas crashed trying to show us the node info.
>
> To manage notifications about this bug go to:
> https:/
>