Sharing files between Linux servers

Source: Internet
Author: User
Tags save file

Vi/etc/exports #需要在root权限下

In the file, insert the following format:

The server IP (rw,no_root_squash,sync) that requires the absolute path of the shared file to accept the file

Save File

Restart Nfs:service NFS Restart or/etc/init.d/nfs restart

Start Protmap:service protmap Restart

Log on to the server that receives the shared directory

Vi/etc/exports

Server IP (rw,no_root_squash,sync) that receives an absolute path that requires shared files to share the file

Restart Nfs:service NFS Restart

To execute mount commands on a server that shares files

MOUNT-T NFS Server IP: Absolute path that requires shared files to receive absolute paths for shared files

The IP that is filled in the exports file can be in the format:

* All IP

Fixed IP/8 can start for 8,16,24,32 such as IP 192.168.1.1/8 on behalf of server IP 192 192.168.1.1/16 on behalf of server IP for 192.168, etc.

Fixed IP receive placed as fixed IP

The parameters after the IP parameters are as follows:

Ro This host has read-only access to the shared directory

RW This host has read and write access to the shared directory

When the Root_squash client accesses the shared folder with the root user, the root user is mapped to an anonymous user

The root user is not mapped when the No_root_squash client accesses the shared folder with root

All_squash mapped to anonymous users when any user on the client access the shared directory

Anonuid A user who maps a user on a client to a specified local user ID

Anongid maps the user on the client to the specified local user group ID

Sync data synchronously written to memory and hard disk

Async data is staged in memory, not directly to the hard disk

Insecure allows unauthorized access from this machine.


Sharing files between Linux servers

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.