delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/01/22/14:28:46

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Thu, 22 Jan 2009 20:28:22 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: ???????? owner and group
Message-ID: <20090122192822.GA25702@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <4977B557 DOT 1070708 AT etr-usa DOT com> <20090122113104 DOT GC17948 AT calimero DOT vinschen DOT de> <4978A932 DOT 5040900 AT etr-usa DOT com>
MIME-Version: 1.0
In-Reply-To: <4978A932.5040900@etr-usa.com>
User-Agent: Mutt/1.5.17 (2007-11-01)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
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 Jan 22 10:13, Warren Young wrote:
> Corinna Vinschen wrote:
>>
>> Have a look into the ACL by using Windows Explorer properties/security
>> dialog.  What you see is thatthe user and group for a file on the share
>> is "Unix User\yourunixuser" and "Unix Group\yourunixgroup".  These
>> accounts are missing in your /etc/passwd and /etc/group files.
>
> Okay, that clears up the Samba side, but what about the local system files?
>
> $ getfacl /c/Windows/regedit.exe
> # file: /c/Windows/regedit.exe
> # owner: ????????
> # group: ????????
> user::rwx
> group::rwx
> group:root:r-x
> group:SYSTEM:r-x
> group:Users:r-x
> mask:rwx
> other:---
>
> I re-ran mkpasswd with no flags, and got the same thing I have in 
> /etc/passwd already.

Have another look into the ACL.  For some reasons only the Microsoft
developers know there's a new account called "TrustedInstaller"
beginning with Vista, which is NOT listed by the account enumeration
functions and which has a SID entirely differnt from your system's SID.
Just ignore it.

>> What you can do:
>>
>> - Add the Unix accounts to /etc/passwd and /etc/group, for instance:
>>
>>   $ mkpasswd -L sambaserver,20000 -U yourunixuser
>>   Unix User\yourunixuser:unused:21000:99999:,S-1-22-1-1000::
>>   $ mkgroup -L sambaserver -U yourunixgroup
>>   Unix Group\yourunixgroup:S-1-22-2-101:20101:
>>
>> - Change the cygdrive flags in /etc/fstab to noacl, which is equivalent
>>   to the old CYGWIN=nosmbntsec.
>
> These are alternatives, right, not two steps that both have to be done?

Right.

> I tried the second part first, figuring that I didn't mind the old 
> nosmbntsec behavior -- all your files are belong to us -- but still got the 
> question marks.
>
> Then I broke down and built up /etc/passwd and /etc/group until all the 
> question marks over Samba went away, then removed the noacl option, 
> restarted all Cygwin stuff, and the question marks are still gone.
>
> So, is noacl not doing what it's supposed to?
>
> If I change the cygdrive fstab entry to:
>
> 	none / cygdrive binary,posix=0,user,noacl 0 0
>
> and restart all of Cygwin, I see:
>
> $ mount
> C:/cygwin/bin on /usr/bin type unknown (binary)
> C:/cygwin/lib on /usr/lib type unknown (binary)
> C:/cygwin on / type unknown (binary)
> C: on /c type ntfs (binary,posix=0,user,noumount)
> D: on /d type ntfs (binary,posix=0,user,noumount)
> T: on /t type smbfs (binary,posix=0,user,noumount)
> U: on /u type smbfs (binary,posix=0,user,noumount)
> V: on /v type smbfs (binary,posix=0,user,noumount)

Please not that mapping the cygdrive prefix to / is NOT supported.  If
something doesn't work as expected, it serves you right and it's all
your own fault and you have been warned and and all that.

My personal cygdrive prefix is /mnt for historical reasons.

> noacl doesn't appear in the mount flags.  Is it incompatible with one of 
> the others?

Works fine for me.  Changes in fstab only have an effect if really *all*
of your Cygwin processes stopped.  If you want a temporary effect in your
current session without having to stop all Cygwin processes, use the mount
command (for instance `mount -f -c /mnt -o posix=0,noacl').  See the user's
guide under http://cygwin.com/1.7/cygwin-ug-net/cygwin-ug-net.html and
http://cygwin.com/1.7/cygwin-ug-net/using-utils.html#mount


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

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