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
Solved

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

Posted on 2007-11-15
5
1,498 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
5 Comments
 
LVL 13

Accepted Solution

by:
WizRd-Linux earned 43 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 41 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 41 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 is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
How to update  and reset admin password for Linux 5 65
How to enable sync between two yum repo? 1 39
error log using ftp 7 56
Upgrade BIOS / EUFI at Scale 4 55
If you use Debian 6 Squeeze and you are tired of looking at the childish graphical GDM login screen that is used by default, here's an easy way to change it. If you've already tried to change it you've probably discovered that none of the old met…
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 get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
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.

861 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