Comment 4 for bug 1532062

Revision history for this message
Scott Moser (smoser) wrote :

ok, so this is wierd, lets focus on 'sda' and see if we can't prune this down.
From your statements in the bug opening:
$ lsblk -l
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 1 100G 0 disk
sda1 8:1 1 100G 0 part /

but then, when we do the longer 'lsblk --bytes --pairs --output=...' command in comment 3, we see:
$ lsblk --bytes --pairs --output=ALIGNMENT,DISC-ALN,DISC-GRAN,DISC-MAX,DISC-ZERO,FSTYPE,GROUP,KNAME,LABEL,LOG-SEC,MAJ:MIN,MIN-IO,MODE,MODEL,MOUNTPOINT,NAME,OPT-IO,OWNER,PHY-SEC,RM,RO,ROTA,RQ-SIZE,SIZE,STATE,TYPE,UUID

ALIGNMENT="0" DISC-ALN="0" DISC-GRAN="0" DISC-MAX="0" DISC-ZERO="0" FSTYPE="" GROUP="disk" KNAME="sda" LABEL="" LOG-SEC="512" MAJ:MIN="8:0" MIN-IO="512" MODE="brw-rw----" MODEL="main " MOUNTPOINT="" NAME="sda" OPT-IO="0" OWNER="root" PHY-SEC="512" RM="1" RO="0" ROTA="1" RQ-SIZE="128" SIZE="107363696640" STATE="running" TYPE="disk" UUID=""
ALIGNMENT="0" DISC-ALN="0" DISC-GRAN="0" DISC-MAX="0" DISC-ZERO="0" FSTYPE="" GROUP="disk" KNAME="sda1" LABEL="" LOG-SEC="512" MAJ:MIN="8:1" MIN-IO="512" MODE="brw-rw----" MODEL="" MOUNTPOINT="/" NAME="sda1" OPT-IO="0" OWNER="root" PHY-SEC="512" RM="1" RO="0" ROTA="1" RQ-SIZE="128" SIZE="107362631168" STATE="" TYPE="part" UUID=""

So it *seems* that in the --output= invocation, it reports they *are* removable, but not in the less verbose invocation.
Lets try to pair that down, can you try:
$ full=ALIGNMENT,DISC-ALN,DISC-GRAN,DISC-MAX,DISC-ZERO,FSTYPE,GROUP,KNAME,LABEL,LOG-SEC,MAJ:MIN,MIN-IO,MODE,MODEL,MOUNTPOINT,NAME,OPT-IO,OWNER,PHY-SEC,RM,RO,ROTA,RQ-SIZE,SIZE,STATE,TYPE,UUID
$ short="NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT"
$ lsblk --pairs "--output=$full" /dev/sda
$ lsblk --pairs "--output=$short" /dev/sda

and then without /dev/sda on it.

See if that shows RM= on any of those. It woudl seem like there must be buffer overflow or something.