【NFS】nfs安装调优
nfs
[root@flymaster ~]# rpm -qa nfs-utils rpcbind
nfs-utils-1.2.3-75.el6.x86_64
rpcbind-0.2.0-13.el6_9.1.x86_64
[root@flymaster ~]#
[root@flymaster ~]# /etc/init.d/rpcbind status
rpcbind 已停
[root@flymaster ~]# /etc/init.d/rpcbind start
Starting rpcbind: [ OK ]
[root@flymaster ~]# /etc/init.d/rpcbind status
rpcbind (pid 1632) is running...
[root@flymaster ~]# lsof -i :111
-bash: lsof: command not found
[root@flymaster ~]# yum install -y lsof
[root@flymaster ~]# lsof -i :111
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
rpcbind 1632 rpc 6u IPv4 13600 0t0 UDP *:sunrpc
rpcbind 1632 rpc 8u IPv4 13603 0t0 TCP *:sunrpc (LISTEN)
rpcbind 1632 rpc 9u IPv6 13605 0t0 UDP *:sunrpc
rpcbind 1632 rpc 11u IPv6 13608 0t0 TCP *:sunrpc (LISTEN)
[root@flymaster ~]# netstat -lnup|grep rpcbind
udp 0 0 0.0.0.0:959 0.0.0.0:* 1632/rpcbind
udp 0 0 0.0.0.0:111 0.0.0.0:* 1632/rpcbind
udp 0 0 :::959 :::* 1632/rpcbind
udp 0 0 :::111 :::* 1632/rpcbind
[root@flymaster ~]# chkconfig --list rpcbind
rpcbind 0:off 1:off 2:on 3:on 4:on 5:on 6:off
[root@flymaster ~]#
[root@flymaster ~]# rpcinfo -p localhost
program vers proto port service
100000 4 tcp 111 portmapper
100000 3 tcp 111 portmapper
100000 2 tcp 111 portmapper
100000 4 udp 111 portmapper
100000 3 udp 111 portmapper
100000 2 udp 111 portmapper
[root@flymaster ~]# /etc/init.d/nfs status
rpc.svcgssd 已停
rpc.mountd is stopped
nfsd is stopped
[root@flymaster ~]# /etc/init.d/nfs start
Starting NFS services: [ OK ]
Starting NFS mountd: [ OK ]
Starting NFS daemon: [ OK ]
正在启动 RPC idmapd: [确定]
[root@flymaster ~]# netstat -lntup|grep 2049
tcp 0 0 0.0.0.0:2049 0.0.0.0:* LISTEN -
tcp 0 0 :::2049 :::* LISTEN -
udp 0 0 0.0.0.0:2049 0.0.0.0:* -
udp 0 0 :::2049 :::*
[root@flymaster ~]# rpcinfo -p localhost
program vers proto port service
100000 4 tcp 111 portmapper
100000 3 tcp 111 portmapper
100000 2 tcp 111 portmapper
100000 4 udp 111 portmapper
100000 3 udp 111 portmapper
100000 2 udp 111 portmapper
100005 1 udp 32888 mountd
100005 1 tcp 34816 mountd
100005 2 udp 60305 mountd
100005 2 tcp 53106 mountd
100005 3 udp 60915 mountd
100005 3 tcp 43298 mountd
100003 2 tcp 2049 nfs
100003 3 tcp 2049 nfs
100003 4 tcp 2049 nfs
100227 2 tcp 2049 nfs_acl
100227 3 tcp 2049 nfs_acl
100003 2 udp 2049 nfs
100003 3 udp 2049 nfs
100003 4 udp 2049 nfs
100227 2 udp 2049 nfs_acl
100227 3 udp 2049 nfs_acl
100021 1 udp 50673 nlockmgr
100021 3 udp 50673 nlockmgr
100021 4 udp 50673 nlockmgr
100021 1 tcp 60233 nlockmgr
100021 3 tcp 60233 nlockmgr
100021 4 tcp 60233 nlockmgr
[root@flymaster ~]# less /etc/init.d/nfs
#!/bin/sh
#
# nfs This shell script takes care of starting and stopping
# the NFS services.
#
# chkconfig: - 30 60
# description: NFS is a popular protocol for file sharing across networks.
# This service provides NFS server functionality, which is \
# configured via the /etc/exports file.
# probe: true
# config: /etc/sysconfig/nfs
### BEGIN INIT INFO
# Provides: nfs
# Required-Start: $local_fs $network $syslog $rpcbind
# Required-Stop: $local_fs $network $syslog $rpcbind
# Default-Stop: 0 1 6
# Short-Description: Start up the NFS server sevice
# Description: NFS is a popular protocol for file sharing across networks \
# This service provides NFS server functionality, \
# which is configured via the /etc/exports file.
### END INIT INFO
[root@flymaster ~]# ps -ef|egrep "rpc|nfs"
root 1734 2 0 15:23 ? 00:00:00 [rpciod/0]
root 1943 1 0 15:27 ? 00:00:00 rpc.mountd
root 1950 2 0 15:27 ? 00:00:00 [nfsd4]
root 1951 2 0 15:27 ? 00:00:00 [nfsd4_callbacks]
root 1952 2 0 15:27 ? 00:00:00 [nfsd]
root 1953 2 0 15:27 ? 00:00:00 [nfsd]
root 1954 2 0 15:27 ? 00:00:00 [nfsd]
root 1955 2 0 15:27 ? 00:00:00 [nfsd]
root 1956 2 0 15:27 ? 00:00:00 [nfsd]
root 1957 2 0 15:27 ? 00:00:00 [nfsd]
root 1958 2 0 15:27 ? 00:00:00 [nfsd]
root 1959 2 0 15:27 ? 00:00:00 [nfsd]
root 1986 1 0 15:27 ? 00:00:00 rpc.idmapd
rpc 2077 1 0 15:32 ? 00:00:00 rpcbind
root 2132 1445 0 15:55 pts/0 00:00:00 egrep rpc|nfs
[root@flymaster ~]# ls -l /etc/exports (nfs配置文件)
-rw-r--r--. 1 root root 0 Jan 12 2010 /etc/exports
echo "/data 192.168.1.*(insecure,rw,sync,no_root_squash)" >/etc/exports
[root@nfs-server101 ~]# mkdir /data
[root@nfs-server101 ~]# /etc/init.d/nfs reload(平滑生效)
[root@nfs-server101 ~]# exportfs -rv
exporting 192.168.1.*:/data
[root@nfs-server101 ~]# showmount -e 127.0.0.1
Export list for 127.0.0.1:
/data 192.168.1.*
[root@nfs-server101 ~]# mount -t nfs 192.168.70.101:/data /mnt
[root@nfs-server101 ~]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg_flymaster-lv_root
18G 977M 16G 6% /
tmpfs 495M 0 495M 0% /dev/shm
/dev/sda1 477M 28M 425M 6% /boot
192.168.70.101:/data 18G 977M 16G 6% /mnt
[root@nfs-server101 ~]# touch /data/fly.txt
[root@nfs-server101 ~]# cd /mnt/
[root@nfs-server101 mnt]# ls
fly.txt
Export list for 192.168.70.101:
/data 192.168.70.*
[root@lamp102 /]# mount -t nfs 192.168.70.101:/data /mnt
[root@lamp102 /]# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg_flymaster-lv_root
18G 976M 16G 6% /
tmpfs 495M 0 495M 0% /dev/shm
/dev/sda1 477M 28M 425M 6% /boot
192.168.70.101:/data 18G 977M 16G 6% /mnt
[root@lamp102 mnt]# grep 65534 /etc/passwd
nfsnobody:x:65534:65534:Anonymous NFS User:/var/lib/nfs:/sbin/nologin
[root@lamp102 mnt]#
【NFS】nfs安装调优的更多相关文章
- 在Oracle数据库中使用NFS,怎样调优?
MOS上有好多文章,基本上都跑不了以下三点: Setup can make a big difference 1. Network topology and load 2. NFS mount opt ...
- NATS_07:NATS之top工具监控以及测量调优工具
概述 你可以使用 nats-top 来实现类似于 linux 中 top 命令的实时监控 nats 服务: 可以使用 nats 提供的工具来进行针对性的调优. 安装nats-top $ go get ...
- 开源服务专题之------sshd服务安装管理及配置文件理解和安全调优
本专题我将讨论一下开源服务,随着开源社区的日趋丰富,开源软件.开源服务,已经成为人类的一种公共资源,发展势头可谓一日千里,所以不可不知.SSHD服务,在我们的linux服务器上经常用到,很重要,涉及到 ...
- CentOS 6.3 NFS的安装配置、启动及mount挂载方法
一.环境介绍: 服务器:centos 192.168.1.225 客户端:centos 192.168.1.226 二.安装: NFS的安装配置: centos 5 : yum -y install ...
- Nginx源码安装及调优配置
导读 由于Nginx本身的一些优点,轻量,开源,易用,越来越多的公司使用nginx作为自己公司的web应用服务器,本文详细介绍nginx源码安装的同时并对nginx进行优化配置. Nginx编译前的优 ...
- Linux下安装、配置、授权、调优Mysql
以前在linux已经安装了很多次的Mysql,但是时间间隔长了以后,安装步骤总是会遗漏,趁这次安装,做一下安装记录. 检查系统是否已经安装Mysql rpm -qa|grep -i mysql Mys ...
- CentOS NFS的安装配置、启动及mount挂载方法
一.环境介绍: 服务器:centos 192.168.1.225 客户端:centos 192.168.1.226 二.安装: NFS的安装配置:centos 5 : yum -y install n ...
- CentOS5、6 NFS的安装配置及mount方法
一.环境介绍: 服务器:centos 192.168.1.225 客户端:centos 192.168.1.226 二.安装: NFS的安装配置:centos 5 : yum -y install n ...
- Centos6.4 NFS的安装与配置
NFS,是Network File System的简写,即网络文件系统.网络文件系统是FreeBSD支持的文件系统中的一种,也被称为NFS. NFS允许一个系统在网络上与他人共享目录和文件.通过使用N ...
随机推荐
- BZOJ 2463: [中山市选2009]谁能赢呢?[智慧]
明和小红经常玩一个博弈游戏.给定一个n×n的棋盘,一个石头被放在棋盘的左上角.他们轮流移动石头.每一回合,选手只能把石头向上,下,左,右四个方向移动一格,并且要求移动到的格子之前不能被访问过.谁不能移 ...
- spring security 4 filter 顺序及作用
Spring Security 有两个作用:认证和授权 一.Srping security 4 filter 别名及顺序 spring security 4 标准filter别名和顺序,因为经常要用就 ...
- 剑指offer试题(PHP篇二)
6.旋转数组的最小数字 题目描述 把一个数组最开始的若干个元素搬到数组的末尾,我们称之为数组的旋转. 输入一个非递减排序的数组的一个旋转,输出旋转数组的最小元素. 例如数组{3,4,5,1,2}为{1 ...
- 【非原创】C++类成员函数的重载、覆盖和隐藏
链接:https://www.nowcoder.com/questionTerminal/266d3a6d4f1b436aabf1eff3156fed95来源:牛客网 题目:类成员函数的重载.覆盖和隐 ...
- c++中对于json的key不带双引号的问题修复
在引用了第三方数据时,数据源通过转义,将json的key上双引号给去掉了. 在PHP开发时,可以通过正则表达式替换方式来补充丢失的双引号,处理代码如下 function ex_json_decode( ...
- H5动画
1.参考:http://blog.csdn.net/whqet/article/details/42911059?readlog https://developer.mozilla.org/zh-CN ...
- 小甲鱼OD学习第12讲
这次我们的任务是破解这个需要特定的注册码的软件,如下图 我们从字符串入手,输入register,搜索 我们点击 查找下一个,看看有什么有用的字符串,如下图 然后,在下方,我们发现了 Regis ...
- Python数据结构之一——list(列表)
Python版本:3.6.2 操作系统:Windows 作者:SmallWZQ Python包含6种常见的内建序列.它们分别是列表.元祖.字符串.Unicode字符串.buffer(memory ...
- Java堆栈内存总结
在Java中,主要存在四块内存空间,除了保存static类型属性的全局数据区,以及保存虽有方法定义的全局代码区之外,程序员更多的在乎内存中的另外两种区域--对象的生存空间堆(heap)和方法调用及变量 ...
- mysql查找以逗号分隔的值-find_in_set
有了FIND_IN_SET这个函数.我们可以设计一个如:一只手机即是智能机,又是Andriod系统的. 比如:有个产品表里有一个type字段,他存储的是产品(手机)类型,有 1.智能机,2.Andri ...