qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH v4 0/1] qemu-ga: add guest-get-osinfo command
@ 2017-06-06 13:32 Tomáš Golembiovský
  2017-06-06 13:32 ` [Qemu-devel] [PATCH v4 1/1] " Tomáš Golembiovský
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Tomáš Golembiovský @ 2017-06-06 13:32 UTC (permalink / raw)
  To: Marc-André Lureau, Eric Blake, Michael Roth,
	Vinzenz 'evilissimo' Feenstra
  Cc: qemu-devel, Tomáš Golembiovský

This is a continuation of the work started by Vinzenz Feenstra in the
threads:

https://lists.nongnu.org/archive/html/qemu-devel/2017-03/msg04154.html
https://lists.nongnu.org/archive/html/qemu-devel/2017-03/msg04302.html
https://lists.nongnu.org/archive/html/qemu-devel/2017-03/msg06262.html

The idea is to report some basic information from uname and from
os-release file, if it is present. On MS Windows, where neither uname
nor os-release exist we fill the values based on the information we can
get from the OS.

The example output on Fedora is:

{
  "return": {
    "kernel-version": "#1 SMP Mon May 8 18:46:06 UTC 2017",
    "kernel-release": "4.10.15-200.fc25.x86_64",
    "machine-hardware": "x86_64",
    "id": "fedora",
    "name": "Fedora",
    "pretty-name": "Fedora 25 (Server Edition)",
    "version": "25 (Server Edition)",
    "variant": "Server Edition",
    "version-id": "25",
    "variant-id": "server"
  }
}

The example output on MS Windows 10 is:

{
  "return": {
    "kernel-version": "10.0",
    "kernel-release": "10240",
    "machine-hardware": "x86_64",
    "id": "mswindows",
    "name": "Microsoft Windows",
    "pretty-name": "Windows 10 Enterprise",
    "version": "Microsoft Windows 10",
    "version-id": "10",
    "variant": "client",
    "variant-id": "client"
  }
}

One issue I see with the current implementation is that one is not able
to distinguish between various (non-linux) POSIX systems from the
returned values. That's because without os-release file (which I assume
is not common on non-linux platforms) only kernel-version,
kernel-release and machine-hardware are returned and telling what OS is
running there is a guessing game. Is this a problem?

Also the qapi documentiaton probably need some polishing. Unfortunately,
so far I was unable to get qapi parser satisfied and still include all
the important information.

    Tomas Golembiovsky

Tomáš Golembiovský (1):
  qemu-ga: add guest-get-osinfo command

 configure            |   2 +-
 qga/commands-posix.c | 155 ++++++++++++++++++++++++++++++++++++++++++++++
 qga/commands-win32.c | 170 +++++++++++++++++++++++++++++++++++++++++++++++++++
 qga/qapi-schema.json |  57 +++++++++++++++++
 4 files changed, 383 insertions(+), 1 deletion(-)

-- 
2.13.0

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-06-07 11:28 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-06 13:32 [Qemu-devel] [PATCH v4 0/1] qemu-ga: add guest-get-osinfo command Tomáš Golembiovský
2017-06-06 13:32 ` [Qemu-devel] [PATCH v4 1/1] " Tomáš Golembiovský
2017-06-06 16:03 ` [Qemu-devel] [PATCH v4 0/1] " no-reply
2017-06-06 18:11 ` no-reply
2017-06-07 11:28 ` Tomáš Golembiovský

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).