Libvirt: Use the virtlogd deamon for logs

Registered by Markus Zoeller (markus_z) on 2015-10-13

If the *serial console* feature is enabled on a compute node with
``[serial_console].enabled = True`` it deactivates the logging of the
boot messages. From a REST API perspective, this means that the two APIs
``os-getConsoleOutput`` and ``os-getSerialConsole`` are mutually exclusive.
Both APIs can be valuable for cloud operators in the case when something
goes wrong during the launch of an instance. This blueprint wants to lift
the XOR relationship between those two REST APIs.

Blueprint information

Status:
Complete
Approver:
Daniel Berrange
Priority:
Medium
Drafter:
Markus Zoeller (markus_z)
Direction:
Approved
Assignee:
Markus Zoeller (markus_z)
Definition:
Approved
Series goal:
Accepted for ocata
Implementation:
Implemented
Milestone target:
milestone icon ocata-2
Started by
Markus Zoeller (markus_z) on 2016-06-02
Completed by
Matt Riedemann on 2016-12-06

Whiteboard

Gerrit topic: https://review.openstack.org/#q,topic:bp/libvirt-virtlogd,n,z

Newton
======

Spec
----

Addressed by: https://review.openstack.org/234291 MERGED
    Libvirt: Use the virtlogd deamon for logs

Changes
-------

Addressed by: https://review.openstack.org/323760 MERGED
    libvirt: virtlogd: use "log" element in char devices

Marking this as Medium priority since it should close our old long-standing security bug for console logs growing indefinitely. -- mriedem 20160602

There are still open changes for this and we're past non-priority feature freeze for Newton so this is going to be deferred to Ocata. Landing the feature with the workaround option because of the qemu bug is the real blocker here, so let's get that sorted out by Ocata so this can get in early in that release. -- mriedem 20160705

Ocata
=====

Spec
----
Addressed by: https://review.openstack.org/382526 MERGED
    Libvirt: Use the virtlogd deamon

Changes
-------

Addressed by: https://review.openstack.org/334480 MERGED
    libvirt: simplify "get_console_output" interface

Addressed by: https://review.openstack.org/323765 ABANDONED
    libvirt: virtlogd: use the logd sub-element for char devices

Addressed by: https://review.openstack.org/385366 MERGED
    libvirt: read rotated "console.log" files

Addressed by: https://review.openstack.org/385367 MERGED
    libvirt: Merge all console device creation into one method

Addressed by: https://review.openstack.org/407120 MERGED
    libvirt: create consoles in an understandable/extensible way

Addressed by: https://review.openstack.org/407450 MERGED
    libvirt: virtlogd: use virtlogd for char devices

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.