public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: L A Walsh <cygwin@tlinx.org>
To: cygwin@cygwin.com
Subject: Re: Treating Junctions consistently, as "normal dirs" as w/linux "bind"-type mount
Date: Thu, 09 Mar 2017 19:13:00 -0000	[thread overview]
Message-ID: <58C1A96D.1030101@tlinx.org> (raw)
In-Reply-To: <20170309164113.GC7716@calimero.vinschen.de>

Corinna Vinschen wrote:
> He's right. The mount point handling in Cygwin is based on the
> in-memory mount table.  
----
    I'm not wanting a mount point fake.  Just wanting it to look
like a normal dir just like the mountvol-junctions.

> There's no reasonable way to fake some
> reparse point to look like a mount point.  We can either handle it
> as normal dir, or as symlink.  Handling it as normal dir is 
> problematic in terms of find/rsync
----
    T All of the core utils are loop-protected in that respect.
same-dev file systems already exist on linux and cygwin.

    File system loops are already present just using mountvol:

>  mountvol
...
\\?\Volume{578b2172-f917-11e4-b3d9-a0369f15ce28}\
        C:\mountedVol\
/mountedVol> mkdir remounted

# note, next "2" lines are really 1 wrapped line:

/mountedVol> mountvol remounted  
'\\?\Volume{578b2172-f917-11e4-b3d9-a0369f15ce28}\'


So the same volume is mounted at C:\mountedVol and at
C:\mountedVol\remounted.
>  etc, bacause the cross-device
> check would fail and files are potentially visited multiple times.
>   
----
That isn't what happens right now with mountvol:

find shows:

/> find mountedVol/ -type d
mountedVol/
mountedVol/$RECYCLE.BIN
mountedVol/$RECYCLE.BIN/S-1-5-21-1885695451-752926663-1105222378-1000
mountedVol/$RECYCLE.BIN/S-1-5-21-1885695451-752926663-1105222378-1025
mountedVol/$RECYCLE.BIN/S-1-5-21-1885695451-752926663-1105222378-500
mountedVol/$RECYCLE.BIN/S-1-5-21-33333-77777-33333-5013
find: File system loop detected; ‘mountedVol/remounted’ is part of the 
same file system loop as ‘mountedVol/’.
mountedVol/System Volume Information

I.e. 'find' (and other coreutils) detect the loop even though
they are the same file system.

Sure, you can find program(s) that are broken and don't detect
such loops, but at least the core utils do check -- and besides,
no one HAS to create junctions -- they can use symlinks as they do
today and no risk of such problems.

But treating linkd-junctions the same as mountvol-junctions allows
those bind-style mounts that are supported on linux and Windows
to be supported on Cygwin.


   

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

  reply	other threads:[~2017-03-09 19:13 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-15 15:30 Cannot access volumes mounted with 'mklink /d' which point to a volume UUID Matt D.
2017-02-16  0:59 ` L. A. Walsh
2017-02-16  9:26 ` Corinna Vinschen
2017-02-24 21:49   ` L. A. Walsh
2017-02-28 21:43     ` Corinna Vinschen
2017-03-02 21:43       ` showing all JUNCTIONS as normal dirs as w/linux --bind (was Re: Cannot access volumes mounted with 'mklink...) L. A. Walsh
2017-03-09  4:17       ` Treating Junctions consistently, as "normal dirs" as w/linux "bind"-type mount L. A. Walsh
2017-03-09 13:50         ` Andrey Repin
2017-03-09 15:48           ` L A Walsh
2017-03-09 16:41             ` Corinna Vinschen
2017-03-09 19:13               ` L A Walsh [this message]
2017-03-10 13:20             ` Andrey Repin
2017-02-16 14:05 ` Cannot access volumes mounted with 'mklink /d' which point to a volume UUID Andrey Repin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=58C1A96D.1030101@tlinx.org \
    --to=cygwin@tlinx.org \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).