Link to home
Start Free TrialLog in
Avatar of josh2780

asked on

Mount windows shares on linux

I'm looking for a way to mount a windows share on a linux box in such a way that when the linux users write data to the mount point, I can (this might be a stretch) map their unix ID to their windows ID for permissions purposes.

I'm aware of using mount.cifs, however, I would have to mount the drive as a particular domain user (a user who has access to the shared NTFS/CIFS folder), however, when linux users modify/write data to the mounted drive, they are accessing the shared deveice as if they were the windows user that mounted the drive.  NFS would be a good alternative here, however, I don't have an NFS server running on the windows box that is hosting the share.

Any suggestions?  Can a Samba client be brought into the picture?  I could automount the drive with the linux user's windows credentials when they login (each linux user has a windows domain account as well), however, I still have to mount the windows drive somewhere at the root level for a web server to be able to access the data, cron scripts to write data to it, etc.  I do not want to mount that drive as my own windows domain account or a system admin domain account.
Avatar of Alundrez
Flag of Australia image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of josh2780


Hi Alundrez,
I was afraid of that... but you are correct - I was thinking that would be the response.  I figured I'd throw this question out there to see if anyone else had run into the same scenario and had done something a bit out of the ordinary to get it to work.  Perhaps not...   but thanks for responding.
I did come across this:

The 'User Name Mapping Service' might be just what I need.  I'll give this a try.
OK - so I've installed the unix services for windows and enabled the NFS service.  The issue now is that I can only create NFS shares for files/folders on a local disk.  The folder that I want to setup as an NFS share is on a NAS and I'm not able to setup an NFS server on it.  So...  this particular windows box that I have has a few of the NAS volumes mapped as well as a windows NFS server running.  This might be a dumb question, but is there a way to force a share (more specifically an NFS share... but this happens to just be an option in "sharing and security" which is not available on mapped drives) on a mapped drive?    I'm digging deep but I think I'm just hitting rock...