Skip to main content
edited tags
Link
Jeff Schaller
  • 68.8k
  • 35
  • 122
  • 267
added 4 characters in body
Source Link
GAD3R
  • 69.9k
  • 32
  • 147
  • 216

theThe following lsblklsblk command print the disk usage in bytes

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk sda disk 298999349248 AVAGO sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO sde disk 98998994944 AVAGO 

how to print the disks when disk is greater than 300000000000 , by adding after the pipe awkawk or perlperl one-liner or else

expected output:

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk | ...... sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO 

the following lsblk command print the disk usage in bytes

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk sda disk 298999349248 AVAGO sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO sde disk 98998994944 AVAGO 

how to print the disks when disk is greater than 300000000000 , by adding after the pipe awk or perl one-liner or else

expected output:

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk | ...... sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO 

The following lsblk command print the disk usage in bytes

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk sda disk 298999349248 AVAGO sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO sde disk 98998994944 AVAGO 

how to print the disks when disk is greater than 300000000000 , by adding after the pipe awk or perl one-liner or else

expected output:

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk | ...... sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO 
Source Link
yael
  • 14k
  • 72
  • 221
  • 377

print line only if number in third field is greater than X

the following lsblk command print the disk usage in bytes

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk sda disk 298999349248 AVAGO sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO sde disk 98998994944 AVAGO 

how to print the disks when disk is greater than 300000000000 , by adding after the pipe awk or perl one-liner or else

expected output:

 lsblk -bio KNAME,TYPE,SIZE,MODEL| grep disk | ...... sdb disk 1998998994944 AVAGO sdc disk 1998998994944 AVAGO sdd disk 1998998994944 AVAGO