* SMB symlink compatibility between Cygwin, Windows XP, and Windows 7
@ 2012-10-04 0:34 Brian Alexander
2012-10-04 12:42 ` Earnie Boyd
0 siblings, 1 reply; 3+ messages in thread
From: Brian Alexander @ 2012-10-04 0:34 UTC (permalink / raw)
To: cygwin; +Cc: briarpatch1337
I have run into an issue when trying to create a symlink/shortcut to a
network share (SMB) that will work between Cygwin, Windows XP, and Windows
7.
If you set the environment variable CYGWIN=winsymlinks, you get the
benefit that ln -s will create files that work as both Windows shortcuts,
and Cygwin symlinks. (Awesome!)
It seems like compatibility is broken between Windows 7 and Windows XP
when it comes to these network links.
My setup:
xpbox is a computer running Windows XP, with cygwin installed,
CYGWIN=winsymlinks
win7box is a computer running Windows 7, with cygwin installed,
CYGWIN=winsymlinks
fileserver is a SMB file server, with shares called "share1" and "share2"
Here is my sequence of commands that leads to my problem:
On xpbox in a cmd window:
net use \\fileserver\share1 /user:domain\username
net use \\fileserver\share2 /user:domain\username
On xpbox in a cygwin terminal:
mkdir //fileserver/share1/folder1
ln -s //fileserver/share1/folder1 //fileserver/share2/link1
Now, when I open up \\fileserver\share2 on xpbox, I see a working shortcut
called "link1" that gets me to \\fileserver\share1\folder1
If I run ls -l //fileserver/share2 in Cygwin, I see that Cygwin recognizes
the link.
If I open up \\fileserver\share2 on win7box though, "link1" is a
non-working shortcut.
More weirdness:
On xpbox in a cygwin terminal:
ln -s //fileserver/share1 //fileserver/share2/link2
link2 is recognized by Windows and Cygwin on both computers.
On win7box in a cygwin terminal:
ln -s //fileserver/share1 //fileserver/share2/link3
ln -s //fileserver/share1/folder1 //fileserver/share2/link4
link3 is not recognized by Windows XP, but works in Windows 7 and Cygwin
on both computers.
link4 is not recognized by Windows XP, but works in Windows 7 and Cygwin
on both computers.
If I use mkshortcut, instead of ln, then the shortcuts work on both
Windows computers, but Cygwin does not recognize the link.
This seems like a compatibility bug in the way Cygwin is making the binary
.lnk files. I haven't had time to look at source code, but that will be
my next step in figuring this out.
Anyone have any other ideas of how to make a shortcut to a SMB path that
will work in both Windows XP and Windows 7, and is also traversable by
cygwin?
Thanks,
Brian Alexander
--
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
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: SMB symlink compatibility between Cygwin, Windows XP, and Windows 7
2012-10-04 0:34 SMB symlink compatibility between Cygwin, Windows XP, and Windows 7 Brian Alexander
@ 2012-10-04 12:42 ` Earnie Boyd
0 siblings, 0 replies; 3+ messages in thread
From: Earnie Boyd @ 2012-10-04 12:42 UTC (permalink / raw)
To: cygwin
On Wed, Oct 3, 2012 at 8:33 PM, Brian Alexander wrote:
>
> Anyone have any other ideas of how to make a shortcut to a SMB path that
> will work in both Windows XP and Windows 7, and is also traversable by
> cygwin?
>
I'm not familiar with CYGWIN=winsymlink to understand what it does; I
can guess but I've not reviewed the code. You could use junction
points for directories. Junction points should work for both XP
(regardless of the service pack) and Win7.
--
Earnie
-- https://sites.google.com/site/earnieboyd
--
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
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: SMB symlink compatibility between Cygwin, Windows XP, and Windows 7
@ 2012-10-04 14:59 Brian Alexander
0 siblings, 0 replies; 3+ messages in thread
From: Brian Alexander @ 2012-10-04 14:59 UTC (permalink / raw)
To: cygwin
>On Wed, Oct 3, 2012 at 8:33 PM, Brian Alexander wrote:
>>
>> Anyone have any other ideas of how to make a shortcut to a SMB path
that
>> will work in both Windows XP and Windows 7, and is also traversable by
>> cygwin?
>>
>
>I'm not familiar with CYGWIN=winsymlink to understand what it does; I
>can guess but I've not reviewed the code. You could use junction
>points for directories. Junction points should work for both XP
>(regardless of the service pack) and Win7.
Unfortunately, junctions do not seem to work with SMB paths, only local
volumes.
Sincerely,
Brian Alexander
--
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
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-10-04 14:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-04 0:34 SMB symlink compatibility between Cygwin, Windows XP, and Windows 7 Brian Alexander
2012-10-04 12:42 ` Earnie Boyd
2012-10-04 14:59 Brian Alexander
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).