blockdev.exe is missing in util-linux. How to determine block device size in bash?

Duncan Roe duncan_roe@optusnet.com.au
Mon Dec 7 02:59:30 GMT 2020


On Sat, Dec 05, 2020 at 12:43:25PM +0300, cygwin wrote:
> Strange. On Win7 this doesn't work:
>
>     il@mar2 /cygdrive/c/Windows/System32
>     $ cat /proc/partitions
>     major minor  #blocks  name   win-mounts
>
>         8     0         0 sda
>         8    16         0 sdb
>
>     il@mar2 /cygdrive/c/Windows/System32
>     $ dd of=/dev/null if=/dev/sda bs=1M count=100
>     100+0 records in
>     100+0 records out
>     104857600 bytes (105 MB, 100 MiB) copied, 0.215181 s, 487 MB/s
>
>
> On 28.11.2020 20:04, Brian Inglis wrote:
> > $ cat /proc/partitions
> > major minor  #blocks  name   win-mounts
> >
> >     8     0 976762584 sda
> >     8     1     16384 sda1
> >     8     2 976744448 sda2   C:\
> >     8    16 976762584 sdb
> >     8    17    131072 sdb1
> >     8    18    102400 sdb2
> >     8    19 975482161 sdb3   D:\
> >     8    20    577536 sdb4
> >     8    21    465920 sdb5
> >     8    32         0 sdc

WFFM with Win7 Home

12:34:05$ cat /proc/partitions
major minor  #blocks  name   win-mounts

    8     0 488386584 sda
    8     1    203776 sda1
    8     2 467246080 sda2   C:\
    8     3  20829184 sda3   D:\
    8     4    105472 sda4   F:\

Cheers ... Duncan.


More information about the Cygwin mailing list