Linux Learning-Server B mounts disk for Server A

Source: Internet
Author: User

Environment: CentOS 7.0

Server B Mounts Server A's disk in 1.centos

Server a:101,.10.0.1
Server b:101.10.12.1
Premise: Ensure that Server A and B have/ifs/data/folders
Purpose: To mount Server A's/ifs/data/folder to its/ifs/data/folder on Server B.

Step1. Edit the/etc/exports file for server a
# vi/etc/exports

Add the following to add trust functionality to Server B

/ifs/data 101.10.12.1 (rw,no_root_squash,no_all_squash,sync)

Enter the following command to make the configuration effective

exportfs-r
STEP2. Mounting a shared disk on Server B

Mount Server A's disk on Server B and enter the command:
Use mount mounts, can only be effective once, restart after the invalid, the command is as follows

101.10.0.1:/ifs/data /ifs/data

If you want to restart and also take effect, you need to modify Server B's/etc/fstab file

vi /etc/fstab

Add the following content

101.10.0.1:/ifs/data   /ifs/data  nfs   defaults    00

Use: Wq after you save the exit, you can use the MOUNT-A command to see if it can be mounted successfully.

Reference post: CentOS torque cluster Configuration (ii) configuring NFS for file sharing in a cluster

This section of the Linux Learning Series will continue to update, welcome to follow this blog: dream_angel_z

Linux Learning-Server B mounts disk for Server A

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.