delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/12/01/12:59:17

X-Spam-Check-By: sourceware.org
Date: Thu, 1 Dec 2005 12:59:05 -0500
From: Christopher Faylor <cgf-no-personal-reply-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: interoperability between samba, linux-cifs, cywgin and sfu
Message-ID: <20051201175905.GA29544@trixie.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
References: <Pine DOT LNX DOT 4 DOT 62 DOT 0511302100160 DOT 4106 AT vmdebian DOT local DOT koeppe-net DOT de>
Mime-Version: 1.0
In-Reply-To: <Pine.LNX.4.62.0511302100160.4106@vmdebian.local.koeppe-net.de>
User-Agent: Mutt/1.5.11
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT 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

On Thu, Dec 01, 2005 at 02:18:10PM +0100, Martin Koeppe wrote:
>Hello,
>
>[please cc me on replies]
>
>while playing around with a Windows server (2003), a Linux server 
>(2.6.11) with Samba (3.0.14a) and a Windows client (2000) with both 
>Interix Services for Unix (SFU) (3.5) and Cygwin (1.5.19pre20051130) 
>installed, I encountered the following problems or inconsistencies 
>when using on the one hand SFU and Cygwin on Windows and Samba network 
>shares, and on the other hand when using linux-cifs on Windows shares, 
>where locally Cygwin or SFU are used.
>
>Most of these problems have been already discussed, and some of them 
>have been solved in between, but I'm cross-posting this summary now to 
>all lists involved on that, I hope at least.
>
>Here interoperability is meant as storing special unix file attributes 
>(special files, mode bits and user/group ids) in such a way, that they 
>ideally are interpreted in the same way by all Windows<->Unix 
>connecting software.
>
>(I have marked in [], which of the software mentioned in this mail's 
>subject I think should be changed for better interoperability.)
>
>
>1. storage of special files such as symlinks, fifos, devs  [all]
>================================================================
>
>The way that SFU stores these special files, I tried to explore at:
>http://lists.samba.org/archive/linux-cifs-client/2005-May/000856.html
>
>Cygwin has its own way which I observed by a quick look (so may not 
>be completely correct):
>http://lists.samba.org/archive/linux-cifs-client/2005-November/001080.html
>
>A concrete problem on cygwin is that you can create device files, but 
>these device files are shown as symlinks instead of as device files 
>(even on C:), i.e.
>
>cygwin$ mknod myblock b 0 0
>cygwin$ ls -l
>lrwxrwxrwx  1 martin mkpasswd  10 Nov 30 23:10 myblock -> :\0:0:61b6
>cygwin$ test -b myblock && echo "block"
>[ does not echo "block", so is not seen as a block device file ]
>cygwin$ test -l myblock && echo "link"
>bash: test: -l: unary operator expected
>cygwin$ perl -e '-l "myblock" && print "link"'
>link
>
>So "test" dies unexpectedly, but perl doesn't. Another problem.

Cygwin didn't consider a device with a major/minor of zero to be a real
device.  This is fixed in CVS.

>cygwin$ mkfifo myfifo && ls -l myfifo
>prw-rw-rw-  1 martin mkpasswd 102 Nov 30 23:09 myfifo
>
>The fifo is made correctly and shown as such, but has a file size of
>102 which is <>0, so not, what I would have expected.

I've also fixed this in CVS but I don't see why it would actually
present a problem.

>2. test -l does not work [cygwin]
>=================================
>
>I repeat this here from above for clarity:
>
>cygwin$ test -l a_link && echo "link"
>bash: test: -l: unary operator expected
>cygwin$ perl -e '-l "a_link" && print "link"'
>link
>
>So "test" dies unexpectedly, but perl doesn't.

test -l (lowercase L) is not equivalent to perl's -l "function".  You
use "test -L" (uppercase L) to check for symlinks.  Unsurprisingly
enough, that works fine on cygwin.

cgf

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