Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How do I auto mount a windows share based on the user logging into the Linux Workstation

Posted on 2007-11-15
5
Medium Priority
?
1,505 Views
Last Modified: 2013-12-16
I have a Fedora Core workstation successfully authenticated it against the windows domain and can login as a windows domain user, mount cifs shares using AD users I just have one last small mission to accomplish.

How do I dynamically mount shares as the user logs in - fstab is all good for mounting a specific share with a specific username but that doesnt fit the bill here (as it wouldnt in most large networks) Basically I need to give each user thier home dir as they login into the Linux box. I'm thinking something like:

\\windows_server\home\%U \\localhost\DOMAIN\%U\Documents\

But with the correct syntax if it is possible

Thanks in advance
0
Comment
Question by:kiwi_nz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 13

Accepted Solution

by:
WizRd-Linux earned 172 total points
ID: 20295516
If all the home directories are in the same directory on the windows server you can install the nfs tools and export the directory.  You could then use autofs to automatically mount the directory to be their home directory.

This way they will have the home directory /home/<domain>/<username> which is automated from the server.

This may not be exactly what you WANT to do, but it is definately a viable solution that could assist you.
0
 
LVL 40

Assisted Solution

by:omarfarid
omarfarid earned 164 total points
ID: 20296498
Hi,

If you choose to use NFS, then please see the links below on how to install and configure NFS on Windows:

http://support.microsoft.com/kb/324055
http://www.microsoft.com/technet/community/events/windows2003srv/tnt1-118.mspx

On the other hand, you may use samba. Please see:

http://us1.samba.org/samba/docs/man/Samba-HOWTO-Collection/
http://us1.samba.org/samba/docs/man/Samba-HOWTO-Collection/install.html#id319843

Now, depending on the login shell of the users (bash, etc), you may use to add a similar command to /etc/profile file:

smbclient  //yourhostname/aservice

Here you need to substiute your server name and share name based on the user name.
0
 

Assisted Solution

by:madscientist159
madscientist159 earned 164 total points
ID: 20393010
What you are looking to do is discussed here under "Mounting shares automatically using libpam-mount"
http://www.hants.lug.org.uk/cgi-bin/wiki.pl?LinuxHints/SambaAuth
0
 
LVL 1

Expert Comment

by:Computer101
ID: 21197927
Forced accept.

Computer101
EE Admin
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question