doc suggestions for User Guide's "Special filenames", including `cat /proc/partitions`
Sun Mar 8 08:36:00 GMT 2009
I was trying to figure out what device mapped to my USB flash drive.
I eventually used `cat /proc/partitions` to determine it was
http://www.cygwin.com/cygwin-ug-net/using-specialnames.html in the
User's Guide covers this topic, but is missing some important
information. Here are seven doc suggestions, five for that page and
two more general.
1. The fixed-font list of devices doesn't explain what /dev/sdb might be, just
On most computers with a single hard disk this will be the first
external mass storage device (though I don't know what "NT internal
device name" that might be).
2. The documentation says "The new fixed POSIX names are mapped to NT
internal devices as follows:" but gives no explanation of what "NT
internal devices" are or how to determine what NT internal device
names such as \device\harddisk1\partition0 your computer has.
http://support.microsoft.com/kb/235128 is a useful starting link,
though it mentions only WinObj.exe that isn't present in Windows XP
(and XP's Start > Programs > Administrative Tools > Computer
Management doesn't reveal these device names).
3. I finally found the answer in
http://sourceware.org/ml/cygwin/2007-05/msg00551.html , where Marco
To have a hint about the device name
$ cat /proc/partitions
That worked for me! this suggestion should go in the documentation, e.g.
To help determine how the disks and partitions available to your
computer map to device names in /dev , enter the two commands
the count of blocks in the output of the two commands will suggest
which drive letter maps to a particular device name (/proc/partitions
will have slightly higher values).
$ cat /proc/partitions
major minor #blocks name
8 0 117220824 sda
8 1 87915681 sda1
8 2 29302560 sda2
8 16 1970175 sdb
8 17 1970159 sdb1
Filesystem 1K-blocks Used Available Use% Mounted on
C:\cygwin\bin 87915680 76099308 11816372 87% /usr/bin
C:\cygwin\lib 87915680 76099308 11816372 87% /usr/lib
C:\cygwin 87915680 76099308 11816372 87% /
df: `/dev/fd0': Not a directory
c: 87915680 76099308 11816372 87% /cygdrive/c
d: 29302556 66940 29235616 1% /cygdrive/d
f: 1969888 44224 1925664 3% /cygdrive/f
This suggests that drive f: is the partition /dev/sdb1 on the disk /dev/sdb.
4. I think a caution that "UNIX gives you access to raw disks and
partitions, but this allows you to utterly destroy existing file
systems on them without a warning" is warranted.
5. The documentation says "If you want to be able to see all devices
in /dev/, you can use Igor Pechtchanski's create_devices.sh script."
BUT! As I understand it, this script is not going to create the right
number of devices for your computer's disks and partitions unless you
modify it, which requires knowing your devices. So the
documentation's "If you want to be able to see all devices in /dev/
..." should be "If you want a directory listing of /dev/ to include
all devices..." , and/or it needs a caveat, something like
This script just creates well-known device names in /dev, regardless
of what hardware devices are actually available on your computer.
6. The user guide web pages should have better <title> tag for
bookmarking, history, and awesome bar. This page title is just
"Special filenames", it should be "Cygwin User's Guide: Special
filenames" or similar.
7. There's no favicon for the user guide pages, unlike e.g. the
cygwin.com home page with its link rel="icon".
I also ran into a glitch where any and every variation of `df
/dev/sdXN` gives information for my first partition, but I'll e-mail
that as a separate bug report.
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
More information about the Cygwin