Relating device names in /dev/ to drive letters in Windows.

Hamish McIntyre-Bhatty hamishmb@live.co.uk
Thu Jul 23 11:29:02 GMT 2020


On 23/07/2020 10:36, Hamish McIntyre-Bhatty wrote:
> Hi all,
>
> I have noticed that after plugging in a USB drive, device files appear
> in /dev that correlate to the partitions on the drive.
>
> This is great because it means things like ddrescue can work in Cygwin,
> but I'm not yet sure how to relate these to the drives Windows sees.
> None of the standard Linux tools I use to gather system information
> (lsblk, blkid, lshw) seem to be available on Cygwin. I'm guessing this
> is because they won't work because there's no kernel or low level
> hardware access or something like that. Does anyone know how to do this?
>
> Hamish
>
Just replying to note that I found
https://www.cygwin.com/cygwin-ug-net/using-specialnames.html, which
covers some of my question.

However, some things (like build in CD/DVD drives) don't show up in
/proc/partitions, so that's still not ideal. Also is there any way I can
get Make/Model and similar information from Cygwin?

I know I can use WMIC or PowerShell for this, but I'm assuming having a
Cygwin package depending on those is a big no-no, even as an alternate
code path if they are detected?

Sorry for all the newbie questions!

Hamish

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0x87B761FE07F548D6.asc
Type: application/pgp-keys
Size: 3183 bytes
Desc: not available
URL: <https://cygwin.com/pipermail/cygwin/attachments/20200723/216bae4c/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://cygwin.com/pipermail/cygwin/attachments/20200723/216bae4c/attachment-0001.sig>


More information about the Cygwin mailing list