This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

File owner set to Unknown+User on cygwin 1.7.35 via samba 3.6.6 on debian


I'm sorry to trouble the group with this, but I've tried hard to resolve it myself and I'm just not making progress.

I have a windows box running the latest stable cygwin (1.7.35) from which I access a debian machine via samba.  I can't get the file owner showing correctly.  I've been reading the ntsec doco, especially the "Samba account mapping" section - but I'm failing to find the right solution.

Looking at files in my home directory on my debian host mounted via samba gives this kind of output:

#: john@johndesktop:~ ; ls -l /cygdrive/l/.bashrc
-rw-r--r-- 1 Unknown+User john 3833 Aug 22  2013 /cygdrive/l/.bashrc

On the debian host, I am:
#: john@johnwl:~ ; id
uid=1000(john) gid=1000(john) groups=1000(john),4(adm),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video),46(plugdev)

On cygwin, I got this from the SAM database:
#: john@johndesktop:~ ; net user john
User name                    john
Full Name                    
Comment                      
User's comment               
Country code                 000 (System Default)
Account active               Yes
Account expires              Never

Password last set            28/05/2013 9:43:28 AM
Password expires             Never
Password changeable          28/05/2013 9:43:28 AM
Password required            No
User may change password     Yes

Workstations allowed         All
Logon script                 
User profile                 
Home directory               
Last logon                   21/04/2015 1:05:52 PM

Logon hours allowed          All

Local Group Memberships      *Administrators       
Global Group memberships     *None                 
The command completed successfully.

AND

#: john@johndesktop:~ ; net localgroup Administrators
Alias name     Administrators
Comment        

Members

-------------------------------------------------------------------------------
Administrator
john
The command completed successfully.

I'm not sure how the group is being translated to "john" in the ls command above with an empty comment field, but that's just good, I suppose. (It's possible I did this when trying to fix this problem a month ago, but I can't work out what did it.)

Since I don't seem to be a member of Users (as mentioned in ntsec doco), but only Administrators, I figured the commands I should run to match my debian box would be

#: john@johndesktop:~ ; net user john /comment:'<cygwin group="Administrators" unix="1000"/>'
The command completed successfully.

and 

#: john@johndesktop:~ ; net localgroup Administrators /comment:'<cygwin unix="1000"/>'
The command completed successfully.

Which gives

#: john@johndesktop:~ ; net user john
User name                    john
Full Name                    
Comment                      <cygwin group="Administrators" unix="1000"/>
User's comment               
Country code                 000 (System Default)
Account active               Yes
Account expires              Never

Password last set            28/05/2013 9:43:28 AM
Password expires             Never
Password changeable          28/05/2013 9:43:28 AM
Password required            No
User may change password     Yes

Workstations allowed         All
Logon script                 
User profile                 
Home directory               
Last logon                   21/04/2015 1:05:52 PM

Logon hours allowed          All

Local Group Memberships      *Administrators       
Global Group memberships     *None                 
The command completed successfully.

#: john@johndesktop:~ ; net localgroup Administrators
Alias name     Administrators
Comment        <cygwin unix="1000"/>

Members

-------------------------------------------------------------------------------
Administrator
john
The command completed successfully.

After a reboot (just to be sure), however, the output is exactly the same:
#: john@johndesktop:~ ; ls -l /cygdrive/l/.bashrc
-rw-r--r-- 1 Unknown+User john 3833 Aug 22  2013 /cygdrive/l/.bashrc

I'd be extremely grateful for any suggestions to fix the user.

Thank you,
John

Attachment: cygcheck.out
Description: Binary data

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

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]