系统环境:Centos7.3

ip1:10.0.0.1

ip2:10.0.0.2

检测是否安装NFS服务

rpm -qa | grep   nfs

rpm  -qa|grep    nfs

安装NFSserver

yum  -y   install    nfs-utils    rpcbind

服务器配置(10.0.0.1)

创建共享目录并设置权限(/mnt/data)

mkdir  -p  /mnt/data

vim   /etc/exports

/mnt/data    10.0.0.0/24(rw,no_root_squash,no_all_squash,sync)

/opt/filestore      *(insecure,rw,no_root_squash)

启动NFSserverfuwu

systemctl enable   rpcbind.service

systemctl enable   nfs-server.service

systemctl   restart    nfs

systemctl    status     nfs

查看 RPC 服务的注册状况

rpcinfo -p   localhost

检测NFS是否联机

showmount -e localhost

客户端配置(10.0.0.2)

安装NFS client服务

yum  -y  install   nfs-utils

创建挂载目录

mkdir   /eason

查看服务器抛出的共享目录信息

showmount    -e    10.0.0.1

为了提高NFS的稳定性,使用TCP协议挂载,NFS默认用UDP协议

mount   -t nfs   10.0.0.1:/mnt/data    /eason   -o   proto=tcp -o nolock

mount   -t nfs   192.168.22.204:/opt/filestore /opt/weixins2/tomcat2/webapps/filestore     -o     proto=tcp    -o    nolock

测试本机

df   -h

服务器端(/mnt/data)

echo "test"  > test.txt

客户端(/eason)

cat    /eason

nfs server and client的更多相关文章

  1. NFS Server宕机后,NFS Client主机上df命令挂死

    方法1: 使用root用户:Oracle@NDMCDB05:~> su -Password: NDMCDB05:~ # cat /etc/mtab /dev/sda2 / reiserfs rw ...

  2. nfs:server 172.168.1.22 not responding,still trying问题解决方法 平台为RealARM 210平台

    nfs:server 172.168.1.22 not responding,still trying问题解决方法 ,平台为RealARM 210平台. 这里的问题是在使用nfs挂载文件系统时遇到的, ...

  3. nfs:server is not responding,still trying 原因与解决

    方案(学自他人) nfs:server is not responding,still trying的解决方法 (2009-04-20 10:20) 方法1 : 我在arm上通过NFS共享文件时出现下 ...

  4. 树莓派 nfs server安装

    安装服务 sudo  apt-get install  portmap sudo  apt-get install  nfs-kernel-server 配置: sudo nano /etc/expo ...

  5. CentOS 7下NFS Server作rootfs时的兼容性问题

    最近新装CentOS 7,发现原先CentOS 6.3下可用的一块ARM Dev board不能用了,表现为VFS mount挂载rootfs失败. 使用WireShark发现,服务器对client发 ...

  6. NFS Server搭建实践

    NFS 是Network File System的缩写,即网络文件系统.一种使用于分散式文件系统的协定,由Sun公司开发,于1984年向外公布.功能是通过网络让不同的机器.不同的操作系统能够彼此分享个 ...

  7. How to Set Up a NFS Server on Debian 10 Buster

    How to Set Up a NFS Server on Debian 10 Buster Nick Congleton Debian 24 May 2019   Contents 1. Softw ...

  8. nfs server的配置 Starting NFS daemon: [FAILED]

    总结了一下是nfs server的制作过程:nfs(Network File System)其实就是说,这个机器的硬盘不够了,我要把文件放到别的服务器上去,服务器端的配置如下:首先(1)确保你的机器上 ...

  9. TCP连接的状态与关闭方式及其对Server与Client的影响

    TCP连接的状态与关闭方式及其对Server与Client的影响 1. TCP连接的状态 首先介绍一下TCP连接建立与关闭过程中的状态.TCP连接过程是状态的转换,促使状态发生转换的因素包括用户调用. ...

随机推荐

  1. 身份认证防止重放攻击的challenge-response方法

    或者叫询问-应答机制. 基于挑战/应答(Challenge/Response)方式的身份认证系统就是每次认证时认证服务器端都给客户端发送一个不同的"挑战"字串,客户端程序收到这个& ...

  2. python tips:作为dict的key的类

    Python的dict由hash实现,解决hash冲突的方法是二次探查法.hash值相同的元素会形成链表.所以dict在查找key时,首先获取hash值,直接得到链表的表头:而后在链表中查找等于key ...

  3. python tips:最内嵌套作用域规则,闭包与装饰器

    在作用域与名字空间提到,python是静态作用域,变量定义的位置决定了变量作用的范围.变量沿着local,global,builtins的路径搜索,直觉上就是从里到外搜索变量,这称为最内嵌套作用域规则 ...

  4. BZOJ 3012: [Usaco2012 Dec]First! 字典树 + tarjan

    Code: #include<bits/stdc++.h> #define maxn 1000003 using namespace std; char str[maxn],strtot[ ...

  5. BPM结束任务

    var pi = tw.system.findProcessInstanceByID("158");for(var i=0; i<pi.tasks.length; i++) ...

  6. Django F查询Q查询Only与Defel

    F/Q查询 测试表 from django.db import models # Create your models here. class MyCharField(models.Field): d ...

  7. C#第三节课(1)

    数据类型 using System;using System.Collections.Generic;using System.Linq;using System.Text;using System. ...

  8. 为什么on用的时候会失效?

    困扰了我一个很久的问题今天终于得带解决了,关于 on 的 用法: $("#hasLabels .link").on("click",function(){ .. ...

  9. cat和cp的神奇用法:制作U盘安装盘

    使用U盘安装debian,U盘的制作方法: 方法一: https://www.debian.org/doc/manuals/debian-handbook/installation.zh-cn.htm ...

  10. Bootstrap内联表单

    有时候我们需要将表单的控件都在一行内显示,就需要将表单控件设置成内联块元素(display:inline-block). 在Bootstrap框架中实现这样的表单效果是轻而易举的,你只需要在<f ...