diff options
author | Karel Zak | 2018-11-29 13:21:36 +0100 |
---|---|---|
committer | Karel Zak | 2018-11-29 13:21:36 +0100 |
commit | 5e91d5dd716ebc6144bcb0cabb0ec847a678be9e (patch) | |
tree | 44a9b4caf14d75fce5a3c4b727e33969237a8abb /misc-utils/blkid.8 | |
parent | mkswap: fix page size warning message (diff) | |
download | kernel-qcow2-util-linux-5e91d5dd716ebc6144bcb0cabb0ec847a678be9e.tar.gz kernel-qcow2-util-linux-5e91d5dd716ebc6144bcb0cabb0ec847a678be9e.tar.xz kernel-qcow2-util-linux-5e91d5dd716ebc6144bcb0cabb0ec847a678be9e.zip |
blkid: make PART_ENTRY_* tags optional (add --no-part-details)
blkid(8) returns information from partition table also for empty
partitions. This is necessary for example for udev, but it could be
confusing if you care about on-device content only.
Default:
# blkid -p /dev/md0p1; echo $?
/dev/md0p1: PART_ENTRY_SCHEME="dos" PART_ENTRY_UUID="6d8796b1-01" PART_ENTRY_TYPE="0x83" PART_ENTRY_NUMBER="1" PART_ENTRY_OFFSET="2048" PART_ENTRY_SIZE="204800" PART_ENTRY_DISK="9:0"
0
With --no-part-details:
# blkid -p /dev/md0p1 --no-part-details; echo $?
2
Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=1653413
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'misc-utils/blkid.8')
-rw-r--r-- | misc-utils/blkid.8 | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/misc-utils/blkid.8 b/misc-utils/blkid.8 index 13b5edb4d..d1cec1dea 100644 --- a/misc-utils/blkid.8 +++ b/misc-utils/blkid.8 @@ -35,6 +35,7 @@ blkid \- locate/print block device attributes .IR list ] .RB [ \-\-usages .IR list ] +.RB [ \-\-no\-part\-details ] .IR device " ..." .IP \fBblkid\fR @@ -114,6 +115,9 @@ Don't encode non-printing characters. The non-printing characters are encoded by ^ and M- notation by default. Note that the \fB\-\-output udev\fR output format uses a different encoding which cannot be disabled. .TP +\fB\-D\fR, \fB\-\-no\-part\-details\fR +Don't print information (PART_ENTRY_* tags) from partition table in low-level probing mode. +.TP \fB\-g\fR, \fB\-\-garbage\-collect\fR Perform a garbage collection pass on the blkid cache to remove devices which no longer exist. @@ -224,7 +228,7 @@ Note that low-level probing also returns information about partition table type (PTTYPE tag) and partitions (PART_ENTRY_* tags). The tag names produced by low-level probing are based on names used internally by libblkid and it may be different than when executed without \fB\-\-probe\fR (for example PART_ENTRY_UUID= vs -PARTUUID=). +PARTUUID=). See also \fB\-\-no\-part\-details\fR. .TP \fB\-s\fR, \fB\-\-match\-tag\fR \fItag\fR For each (specified) device, show only the tags that match |