X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-4.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI X-Spam-Check-By: sourceware.org From: "Schwarz, Konrad" <konrad DOT schwarz AT siemens DOT com> To: "cygwin AT cygwin DOT com" <cygwin AT cygwin DOT com> Date: Thu, 28 Jul 2011 10:18:26 +0200 Subject: RE: Device names in /proc/mounts Message-ID: <9B10FEAACF062F48A095880A451FF0590380B9DAEF@DEMCHP99E84MSX.ww902.siemens.net> References: <20110727094051 DOT GA28312 AT calimero DOT vinschen DOT de> In-Reply-To: <20110727094051.GA28312@calimero.vinschen.de> Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: <cygwin.cygwin.com> 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 Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id p6S8J1wv006904 > From: Corinna Vinschen > Sent: Wednesday, July 27, 2011 11:41 AM > Subject: Re: Device names in /proc/mounts > D:/foo/bar /baz xyz binary,posix=0 0 0 > //server/share/some/path /home/dummy smbfs binary,noacl 0 0 > > how would you map them to devices? Both paths are not > devices, except that they are equivalent to the NT kernel paths > > \Device\HarddiskVolume3\foo\bar > \Device\Mup\server\share\some\path Why not display these (in /proc/mounts) as /cygdrive/d/foo/bar /baz bind ... //server/share/some/path /home/dummy bind ... I think this is the Linux bind mount syntax. > > In Cygwin, there is no way of figuring out where /dev/sdXY > is mounted. > > Yes, for the simple reason that they are not mounted in > Cygwin, but only in NT. What you're asking for just doesn't > make sense in this context. As far as I understand, Cygwin mount knows about - fixed mounts /, /usr/bin, /usr/lib - user-defined mounts taken from /etc/fstab, /etc/fstab.d, and the command-line - Win32 drive letters implicitly mounted under /cygdrive The last case is actually handled by Windows, as you point out. What would be the problem (otherwise than backwards compatibility) in using Cygwin device names in this last case? For the second case (and the first, should you so desire), you could use the /cygdrive prefix or //server/share notation, as above. > No. There is no reason to carry the Linux compatibility to > such extremes. Forcing the users to use device names in > /etc/fstab just won't fly. Let's use the above two examples again: > > D:/foo/bar /baz xyz binary,posix=0 0 0 > //server/share/some/path /home/dummy smbfs binary,noacl 0 0 > > What would you like to see in fstab for both of them? > > /Device/HarddiskVolume3/foo/bar /baz xyz binary,posix=0 0 0 > > or > > /dev/sdb1/foo/bar /baz xyz binary,posix=0 0 0 > > Both are not Linux compatible either, since you can't use > expressions like /dev/sdb1/foo/bar under Linux to access > subdirectories on a drive. Well, I would use /cygdrive/d/foo/bar /baz bind ... as I suggested above. Even better would be if Linux rebinding did it this way. But mostly I would like /dev/sda1 /cygdrive/c ntfs ... rather than C: /cygdrive/c ntfs ... > And what about remote shares? > > /Device/Mup/server/share/some/path /home/dummy smbfs > binary,noacl 0 0 > > Where's the POSIX device here? There is none. Do you want > to invent one, like, say, /dev/mup? There's no equivalent > device on Linux. Again, as suggested above: //server/share/some/path /home/dummy smbs ... > Cygwin tries to have a Linux-like API. > But it's running on Win32. So there are limitation what we > can do and what makes sense, given the context. I quite understand, it's just that I think you could sensibly stretch the limits a little bit more in this case :-). -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple