I am working on a tool which reads raw from a disk via cygwin's /dev/sdX interface, which works fine. But I need to determine the size of the disk preferably in sectors. I can not find a get ata identity functionality in cygwin, but I can live without it if I could get the disk size elsewhere. My disk is 40 Gb which is divided in to two partitions on 20Gb each. "df" reports 19567136 and 20625392 1k-blocks each, which is the correct size. But /proc/partitions says 313074216 and 330167880 which is about a factor 0.0625 of compared to linux. Why this strange factor it seems like you accidently multiplied by 16.
My cygwin version is 1.5.5-1
/Christian
--------------------------- Dump of my win2k running cygwin [EMAIL PROTECTED] /usr/bin 3670-4 $ cat /proc/partitions major minor #blocks name
17 32 643242600 sda 17 33 313074216 sda1 17 34 330167880 sda2
[EMAIL PROTECTED] /usr/bin 3670-4
$ df
Filesystem 1k-blocks Used Available Use% Mounted on
C:\cygwin\usr\X11R6\lib\X11\fonts
19567136 13020552 6546584 67% /usr/X11R6/lib/X11/fonts
C:\cygwin\bin 19567136 13020552 6546584 67% /usr/bin
C:\cygwin\lib 19567136 13020552 6546584 67% /usr/lib
C:\cygwin 19567136 13020552 6546584 67% /
c: 19567136 13020552 6546584 67% /cygdrive/c
h: 20625392 15101200 5524192 74% /cygdrive/h
------------------- Dump of linux server --- [EMAIL PROTECTED] ~/unixenv 3670-4 $ cat /proc/partitions major minor #blocks name
9 0 2931776 md0 9 1 2931776 md1 9 2 14490560 md2 9 3 14498560 md3 9 4 28988992 md4 9 5 70830336 md5 8 0 17921835 sda 8 1 489951 sda1 8 2 2931862 sda2 8 3 14498662 sda3 8 16 17921835 sdb 8 17 489951 sdb1 8 18 2931862 sdb2 8 19 14498662 sdb3 8 32 35916548 sdc 8 33 497983 sdc1 8 34 35415292 sdc2 8 48 17921835 sdd 8 49 489951 sdd1 8 50 2931862 sdd2 8 51 14498662 sdd3 8 64 17921835 sde 8 65 489951 sde1 8 66 2931862 sde2 8 67 14498662 sde3 8 80 35916548 sdf 8 81 497983 sdf1 8 82 35415292 sdf2 3 0 39082680 hda 3 1 39078081 hda1
[EMAIL PROTECTED] ~/unixenv 3670-4 $ df Filesystem 1k-blocks Used Available Use% Mounted on rootfs 2885728 2696840 42300 99% / /dev/root 2885728 2696840 42300 99% / /dev/md5 69717728 11478056 54698156 18% /store2 /dev/hda1 38464340 24432912 12077524 67% /store1 AFS 9000000 0 9000000 0% /afs /dev/md4 28533316 23185864 3898004 86% /home
-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/