Vgs: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 38: Line 38:


Output unit: (h)uman-readable, (b)ytes, (s)ectors, (k)ilobytes, (m)egabytes, (g)igabytes, (t)erabytes, (p)etabytes, (e)xabytes.  Capitalise to use multiples of 1000 (S.I.) instead of 1024.
Output unit: (h)uman-readable, (b)ytes, (s)ectors, (k)ilobytes, (m)egabytes, (g)igabytes, (t)erabytes, (p)etabytes, (e)xabytes.  Capitalise to use multiples of 1000 (S.I.) instead of 1024.
==--nosuffix==
Suppress the suffix on output sizes.  Use with [[#--units|--units]].


=Example=
=Example=

Revision as of 04:27, 23 May 2017

Internal

Overview

Command that provides information information about volume groups.

# vgs
  VG        #PV #LV #SN Attr   VSize   VFree
  docker_vg   1   0   0 wz--n- 508.00m 508.00m
  main_vg     1   1   0 wz--n-   7.00g      0

Options

--noheadings

Drops headers, useful when the output if mechanically processed.

-o

Options, displays various fields:

  • vg_name - displays the volume group name.
  • vg_free - free space in the volume group. Also see --units.

-S

Select: Display only rows that match selection criteria. The fields that can be used are listed in the -o section.

-S vg_name=${something},...

--units

Output unit: (h)uman-readable, (b)ytes, (s)ectors, (k)ilobytes, (m)egabytes, (g)igabytes, (t)erabytes, (p)etabytes, (e)xabytes. Capitalise to use multiples of 1000 (S.I.) instead of 1024.

--nosuffix

Suppress the suffix on output sizes. Use with --units.

Example

Free Space in the Volume Group

The amount of free space in bytes on a volume group:

vgs --noheadings --nosuffix --units b -o vg_free  docker_vg