Configure the NFS service of Ubuntu10.10

Source: Internet
Author: User
Configure the NFS service (Ubuntu-10.10-desktop) NFS (NetworkFileSystem, Network File System) to share directories of different hosts (different OS) over the network-directories of remote hosts can be mounted through NFS, accessing this directory is like accessing a local directory! (It is best to switch to the root user before the operation) to install the NFS server and client: sudoapt-getinstallnfs-kernel-ser

Configure NFS service (Ubuntu-10.10-desktop)

Network File System (NFS) allows you to share directories of different hosts (OS) over the Network-you can mount directories of remote hosts through NFS, accessing this directory is like accessing a local directory! (It is best to switch to the root user before the operation)


Install the NFS server and client:

Sudo apt-get install nfs-kernel-server nfs-common portmap
Prompt whether to continue: Y

Do you want to continue [Y/n]? Y
The client can be installed to test the NFS service on the local machine.

Configure portmap

Sudo dpkg-reconfigure portmap
Select "No" after running"

Configure the Mount directory and permissions

Vim/etc/exports
My configuration is as follows:

#/Etc/exports: the access control list for filesystems which may be exported
# To NFS clients. See exports (5 ).
#
# Example for NFSv2 and NFSv3:
#/Srv/homes hostname1 (rw, sync) hostname2 (ro, sync)
#
# Example for NFSv4:
#/Srv/nfs4 gss/krb5i (rw, sync, fsid = 0, crossmnt)
#/Srv/nfs4/homes gss/krb5i (rw, sync)
#
/Home/cevin/nfs * (rw, sync, no_root_squash) Note) there is a space in front *.

Explanations:

# Subsequent explanations

/Home/cevin/nfs is the NFS shared directory. * indicates that any IP Address can share this directory. You can change it to a restricted IP address. rw indicates the permission and sync indicates the default one.

Restart the NFS service

Sudo/etc/init. d/nfs-kernel-server restart // restart the nfs service
Try mounting a local disk and mount/home/cevin/nfs to/mnt

Root@linuxidc.com: // # mount-t nfs 192.168.0.110:/home/cevin/nfs mnt // 192.168.0.110 is your own IP
Run df to see the result:

Root@linuxidc.com:/# df
192.168.0.110:/home/cevin/nfs
19737280 2962304 15772352 16%/mnt


Mounted successfully. Tested. unmounted

Root@linuxidc.com:/# umount mnt/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.