Documente Academic
Documente Profesional
Documente Cultură
Mounting NFS Filesystem (Linux-to-Linux) or CIFS Share (Common Internet File Share,
for example Linux-to-Windows)
Mounting NFS Filesystem or CIFS share means to make a remote NFS (Network File Sharing
LINUX-to-LINUX Sharing)
filesystem as though it were a local file system.
2. Determine the mount point where it should be mounted and create the mount point's
directory
# mkdir /remote1
# mkdir /remote2
# vim /etc/fstab
Practice LAB:
# showmount -e server1.example.com
1/4
RH135-Day14
# mkdir /extra
# vim /etc/fstab
Creating entry in /etc/ftab (as mantioned above) will keep connection to network server active
always. Alternatively
, the automounter or autofs service can be configured to mount network shares "on demand"
and unmount after a
certain amount of inactivity. There is two ways to configure the automounter service.
By default, with the autofs service running whenever you enter (that means cd) to the
/net/nfsserver.domain
directory you'll get the all NFS exports available from that NFS server. Once the directories
underneath stop being
used, the shares become unmounted and the nfsserver.domain subedirectory in /net is
removed.
Practice LAB:
# showmount -e server1.example.com
2/4
RH135-Day14
# ls /net <-- you'll see the directory is empty. because still we didnt browse into this directory
# cd /net/server1.example.com
# ls <---- you'll see all exported directory from server1.example.com
# cd ~
# ls /mnt/ <--- you'll get nothing in this folder
Indirect Map:
Indirect Maps allow the system administrator to identify a particular network share and
determine the mount point in
any directory as his wish (unlike direct MAP where the mount point is always /net directory)
- /etc/auto.master will have one line for each "parent" directory to manage and the name of an
individual second
# cat /etc/auto.master
/demo /etc/auto.demo
- /etc/auto.demo file contains the sub-directory (for example public) mount point and network
share with mount
opttions
# cat /etc/auto.demo
* Students are advised to follow page 101 and 10 for more detail
3/4
RH135-Day14
Practice LAB:
Configure your workstation such that autofs automaticaly mounts that share as: /special/oshu
/special /etc/auto.special
# vim /etc/auto.special
4/4