xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Dan Magenheimer <dan.magenheimer@oracle.com>
To: Ian Jackson <Ian.Jackson@eu.citrix.com>,
	Ian Campbell <Ian.Campbell@citrix.com>
Cc: xen-devel@lists.xen.org
Subject: Re: [PATCH] xen-tmem-list-parse: fix ugly parse output
Date: Thu, 15 Nov 2012 16:06:57 -0800 (PST)	[thread overview]
Message-ID: <a667ce8c-29c3-4219-bd02-38a5a9f176e8@default> (raw)
In-Reply-To: <20643.35236.734433.350743@mariner.uk.xensource.com>

> From: Ian Jackson [mailto:Ian.Jackson@eu.citrix.com]
> Subject: Re: [PATCH] xen-tmem-list-parse: fix ugly parse output
> 
> Ian Campbell writes ("Re: [PATCH] xen-tmem-list-parse: fix ugly parse output"):
> > On Wed, 2012-11-14 at 00:08 +0000, Dan Magenheimer wrote:
> >
> > > > Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com>
> >
> > Acked-by: Ian Campbell <ian.campbell@citrix.com> and applied, sorry for
> > the delay.
> 
> I'm happy to backport this to 4.2.  Since none of this is tested by
> the autotests and the change is self-contained, there is no point
> waiting to see if it survives in -unstable and I have done so right
> away.
> 
> As for 4.1, I think that's really very much in the deep freeze and
> receiving essential bug/compatibility/security fixes only so I would
> be inclined to punt on this patch.
> 
> I have another comment though:
> 
>   The program xen-tmem-list-parse parses the output of xm/xl tmem-list
>   into human-readable format.  A missing NULL terminator sometimes
>   causes garbage to be spewed where the two-letter pool type
>   should be output.
> 
> Would it not be much better if  xl tmem-list  produced a sane format
> to start with ?  I haven't seen what the old and new formats are like
> but in general I think  xl foo-list  should produce information useful
> to humans.
> 
> In xl for the future we should be providing json output for things
> which need to be machine-readable.  This may need a transition plan of
> course.

The real consumer of the tmem-list is a toolstack.  It contains a wealth
of information that might be useful to automatic balancing tools
(for balancing across multiple machines, not so much VMs within a single
machine).  So a long-winded-hard-to-parse-but-human-readable format
didn't seem wise.  Also, because it was not clear at the time (and
still isn't) which of the listed data would be useful, or if more
would be even more useful, I chose a format where more or less
data could be provided forwards- and backwards-compatible across
multiple generations of tools parsing the data.

BUT, the data is also useful for debugging and for experimenters
trying tmem to observe what is going on (I often used
"watch -d 'xm tmem-list | xen-tmem-list-parse'"),
so I hacked up a parsing program to make it human readable.

That's just the history... I am very open to a different approach
as long as it meets the needs described above.  Someone with
a different set of skills than I will need to take it on though.

Thanks,
Dan

      reply	other threads:[~2012-11-16  0:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-01 16:42 [PATCH] xen-tmem-list-parse: fix ugly parse output Dan Magenheimer
2012-11-14  0:08 ` Dan Magenheimer
2012-11-14 10:24   ` Ian Campbell
2012-11-14 12:08     ` Ian Jackson
2012-11-16  0:06       ` Dan Magenheimer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a667ce8c-29c3-4219-bd02-38a5a9f176e8@default \
    --to=dan.magenheimer@oracle.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).