delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/06/17/15:32:30

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <2380.130.240.136.220.1119036731.squirrel@pinus.tt.luth.se>
In-Reply-To: <42B269D5.2050907@hq.astra.ph>
References: <42B2687C DOT 4010601 AT vecernik DOT at> <42B269D5 DOT 2050907 AT hq DOT astra DOT ph>
Date: Fri, 17 Jun 2005 21:32:11 +0200 (CEST)
Subject: Re: POSIX devices
From: "Bengt-Arne Fjellner" <Bengt-Arne DOT Fjellner AT ltu DOT se>
To: cygwin AT cygwin DOT com
User-Agent: SquirrelMail/1.4.4
MIME-Version: 1.0

Carlo Florendo wrote:
> Oliver Vecernik wrote:
>
>>Hi all,
>>
>>I'd like to inspect some MBR's from various devices. I have an external
>>Firewire disk (x:), an USB stick (e:) and a flash card (F:, pcmcia).
>>

<snip>

>>But how do I know the order of device names? It all depends when the
>>devices are plugged on to the system. Is there a command to find out?
>>
>>dd if=/dev/sd? of=/tmp/foo bs=512 count=1
>>
>>
>>
>
> AFAIK, Cygwin does not implement the /dev directory.
>
> I'm afraid there is no cygwin command to find out the order of devices
> plugged to the system although I'd be glad if someone corrects me and
> says that there is.

There is. (or rather will be. I think it might be in the pipeline).
if you want to check it check
http://pinus.tt.ltu.se/~baf/dkoll.tgz
dkoll.c is cygwin source the rest is visual studio
build by make dkoll
dkoll.exe is the compiled cygwin version which gives on my system:

$ ./dkoll
Disk 0  cygwin=/dev/sda
dsig a853000400000080
Disksize 18GB
 part    len typ

Disk 1  cygwin=/dev/sdb
dsig a05f20122a744c01
Disksize 74GB
 part    len typ
    1   54MB 222 Dell system          Dell 4.1
    2   59GB   7 NTFS                 NTFS
    3  502MB  12 FAT 32 (xp)          MSWIN4.1
    4   13GB 131 Linux Native         ext3 LILO
    5  996MB 130 Linux Swap           SWAP

Disk 2  cygwin=/dev/sdc
dsig c282801c8e9ce5bf
Disksize 115GB
 part    len typ
    1  115GB 131 Linux Native         XFS

Disk 3  cygwin=/dev/sdd
dsig f99e600d8e82ca7b
Disksize 55GB
 part    len typ
    1   55GB   7 NTFS                 NTFS

Disk 4  cygwin=/dev/sde
dsig 7de080005cf52c49
Disksize 2.0GB
 part    len typ
    1  2.0GB 131 Linux Native         ext2

baf AT bafstat3 ~/dkoll
$
so you get windows disk number. cygwin /ev/sdX disksize and partition size
plus a good guess of what filesystem it has. NOT always perfect.
The partition number is the the same as Y in /dev/sdXY
Hope this helps.

>
> Thank you very much.
>
> Best Regards,
>
> Carlo
>
> --
> Carlo Florendo
> Astra Philippines Inc.
> www.astra.ph

-- 
Bengt-Arne Fjellner
0910-58 53 69



--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019