LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Problems accessing Windows with SAMBA (group users) (https://www.linuxquestions.org/questions/linux-networking-3/problems-accessing-windows-with-samba-group-users-455217/)

Micro420 06-15-2006 07:39 PM

Problems accessing Windows with SAMBA (group users)
 
I have 2 accounts on the Linux box (192.168.0.2): John and Jane. (UID=500 and UID=501, respectively)
They are part of the ACCOUNTING group (GID=512)

I also have the same accounts, John and Jane, on a Windows 2000 file sharing server (192.168.0.3) with the same password as the Linux box (just to make things easier). I am trying to share the c:\accounting folder for them. Sharing and security permissions are set appropriately to John and Jane.

On the Linux box, I create, as root, a /mnt/accounting folder.

I then have in my /etc/fstab the following:

//192.168.0.3/accounting /mnt/accounting smbfs username=john,password=XXXXXX uid=500,gid=512 0 0
//192.168.0.3/accounting /mnt/accounting smbfs username=jane,password=XXXXXX uid=501,gid=512 0 0

I am then able to access the /mnt/accounting folder as a user. Problem is that Jane can read/write to it, but John cannot read/write to it. It seems that since Jane is on the bottom of the list, it cancels out the previous permission for John (UID=500).

How do I do it so BOTH of them get read and write access to the /mnt/accounting folder? If I switch John and Jane around in the /etc/fstab, then John gets read and write permission but Jane does not.

Thanks

BrianK 06-15-2006 09:05 PM

well, you can't make two mounts to the same folder... If you want to mount them separately (which is a question should should answer yourself - do they need separate logins through samba?), you'll have to either make two mounts /mnt/accountingjohn & /mnt/accountingjane (or possible /mnt/account/john & jane) or allow john & jane to mount the drive themselves.

This, of course, is all AFAIK.

You *can* run nfs on Windows so that you only have one mount & let nfs deal with uids & such. ::shrug::

Micro420 06-15-2006 10:05 PM

LOL! I see what you are saying. So it's best just to have each user on their own workstation create their individual /mnt directory, like what you said?

/mnt/accountingjohn
/mnt/accountingjane

The files will still be "udpated" in real time, correct? for example, if John makes a change, Jane will also see the changes and vice versa?

Your idea sounds very simple. I feel so stupid! LOL

Micro420 06-15-2006 10:37 PM

Is there any way for me to encrypt the username/password in the /etc/fstab? I don't like the idea of it being in plain text and having to ask the users for their passwords or to see their passwords when I edit the fstab


All times are GMT -5. The time now is 06:56 AM.