Re: [PATCH 0/5] lscpu: improve hypervisor detection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 20, 2014 at 06:34:22PM +0200, Stanislav Brabec wrote:
> Ruediger Meierwrote:
> 
> > I've splitted the original patch into smaller pieces, removed some
> > incompatible output format changes and added some test data.
> 
> There was a controversial part of this patch, that causes test failure.
> 
> There should be a way how to output result of the virtual machine
> detection without breaking test cases (and possibly existing scripts).

Like many other utils we have a way how to specify output columns

  lscpu --extended[=<list>]
  lscpu --parse[=<list>]

The man page:

  -p, --parse[=list]

  If  the  list  argument is omitted, the command output is compatible
  with earlier versions of lscpu. 

it means that HvVendor,VirtType have to be omitted from -p by default.


Frankly, I don't see any practical reason to have hypervisor info in -p
and -e at all. These output formats are about CPU topology and per-CPU
specific information. The global stuff makes more sense for the default
(without options) output where you can use 

    lscpu | awk '/Hypervisor type/ { print $2 }'

or so...

    Karel


-- 
 Karel Zak  <kzak@xxxxxxxxxx>
 http://karelzak.blogspot.com
--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux