NFS configuration and usage note (in Ubuntu9.10 and Fedora 10 )
来源:互联网 发布:农村淘宝运营面试 编辑:程序博客网 时间:2024/04/29 14:51
1. NFS configuration , install package:( in Ubuntu)
root@vinco:/home/vinco# apt-get install nfs-kernel-serverReading package lists... DoneBuilding dependency tree Reading state information... DoneThe following extra packages will be installed: libgssglue1 libnfsidmap2 librpcsecgss3 nfs-common portmapThe following NEW packages will be installed: libgssglue1 libnfsidmap2 librpcsecgss3 nfs-common nfs-kernel-server portmap0 upgraded, 6 newly installed, 0 to remove and 323 not upgraded.Need to get 490kB of archives.After this operation, 1,528kB of additional disk space will be used.Do you want to continue [Y/n]? YGet:1 http://cn.archive.ubuntu.com karmic/main libgssglue1 0.1-3 [23.6kB]Get:2 http://cn.archive.ubuntu.com karmic/main libnfsidmap2 0.21-2 [28.4kB]Get:3 http://cn.archive.ubuntu.com karmic/main librpcsecgss3 0.18-1 [32.4kB]Get:4 http://cn.archive.ubuntu.com karmic/main portmap 6.0-10ubuntu2 [37.4kB]Get:5 http://cn.archive.ubuntu.com karmic/main nfs-common 1:1.2.0-2ubuntu8 [211kB]Get:6 http://cn.archive.ubuntu.com karmic/main nfs-kernel-server 1:1.2.0-2ubuntu8 [158kB] Fetched 490kB in 9s (51.0kB/s) Preconfiguring packages ...Selecting previously deselected package libgssglue1.(Reading database ... 135173 files and directories currently installed.)Unpacking libgssglue1 (from .../libgssglue1_0.1-3_i386.deb) ...Selecting previously deselected package libnfsidmap2.Unpacking libnfsidmap2 (from .../libnfsidmap2_0.21-2_i386.deb) ...Selecting previously deselected package librpcsecgss3.Unpacking librpcsecgss3 (from .../librpcsecgss3_0.18-1_i386.deb) ...Selecting previously deselected package portmap.Unpacking portmap (from .../portmap_6.0-10ubuntu2_i386.deb) ...Selecting previously deselected package nfs-common.Unpacking nfs-common (from .../nfs-common_1%3a1.2.0-2ubuntu8_i386.deb) ...Selecting previously deselected package nfs-kernel-server.Unpacking nfs-kernel-server (from .../nfs-kernel-server_1%3a1.2.0-2ubuntu8_i386.deb) ...Processing triggers for man-db ...Processing triggers for sreadahead ...Setting up libgssglue1 (0.1-3) ...Setting up libnfsidmap2 (0.21-2) ...Setting up librpcsecgss3 (0.18-1) ...Setting up portmap (6.0-10ubuntu2) ...portmap start/running, process 18021Setting up nfs-common (1:1.2.0-2ubuntu8) ...Creating config file /etc/idmapd.conf with new versionCreating config file /etc/default/nfs-common with new versionAdding system user `statd' (UID 115) ...Adding new user `statd' (UID 115) with group `nogroup' ...Not creating home directory `/var/lib/nfs'.statd start/running, process 18248gssd stop/pre-start, process 18273idmapd stop/pre-start, process 18301Setting up nfs-kernel-server (1:1.2.0-2ubuntu8) ...Creating config file /etc/exports with new versionCreating config file /etc/default/nfs-kernel-server with new version * Exporting directories for NFS kernel daemon... [ OK ] * Starting NFS kernel daemon [ OK ] Processing triggers for libc-bin ...ldconfig deferred processing now taking placeroot@vinco:/home/vinco#
2. usage notes (in Ubuntu9.10 and Fedora10 )
(1) nfs mount in local host ( ubuntu )
i. mkdir nfs
root@vinco:/# mkdir nfsdirroot@vinco:/# chmod 777 -R /nfsdir/root@vinco:/# ll -a nfsdirtotal 8drwxrwxrwx 2 root root 4096 2011-07-25 11:45 .drwxr-xr-x 22 root root 4096 2011-07-25 11:45 ..
ii.add a line as below:
root@vinco:/home/vinco# vim /etc/exports /nfsdir *(sync,rw,no_root_squash)
iii. restart the nfs:
root@vinco:/home/vinco# /etc/init.d/nfs-kernel-server restart * Stopping NFS kernel daemon [ OK ] * Unexporting directories for NFS kernel daemon... [ OK ] * Exporting directories for NFS kernel daemon... exportfs: /etc/exports [1]: Neither 'subtree_check' or 'no_subtree_check' specified for export "*:/nfsdir". Assuming default behaviour ('no_subtree_check'). NOTE: this default has changed since nfs-utils version 1.0.x [ OK ] * Starting NFS kernel daemon
iv. restart the portmap
root@vinco:/home/vinco# /etc/init.d/portmap restartRather than invoking init scripts through /etc/init.d, use the service(8)utility, e.g. service portmap restartSince the script you are attempting to invoke has been converted to anUpstart job, you may also use the restart(8) utility, e.g. restart portmapportmap start/running, process 800root@vinco:/home/vinco# service portmap restartportmap start/running, process 800
v. try mount in local machine(192.168.152.144)
--------in console one:
root@vinco:/# cd nfsdir/root@vinco:/nfsdir# touch nfs.txtroot@vinco:/nfsdir# lltotal 0-rw-r--r-- 1 root root 0 2011-07-25 12:25 nfs.txt
--------in anther console
root@vinco:/home/vinco# mount -t nfs 192.168.152.144:/nfsdir/ /mnt/root@vinco:/home/vinco# ls /mnt/nfs.txt--------successfull
- NFS configuration and usage note (in Ubuntu9.10 and Fedora 10 )
- git usage and configuration
- Quartz.NET教程_Lesson 10: Configuration, Resource Usage and SchedulerFactory
- ubuntu9.10 NFS设置
- Configuration of DLL usage in VS2005--how to add additionl lib and head file
- Dependencies and configuration in detail
- Dependencies and configuration in detail
- skpye 4.3 installation and configuration in linux CentOS 7 / RHEL 7 / Fedora 20
- ubuntu9.10构建nfs服务器端
- Ubuntu9.10建立NFS服务
- Ubuntu9.10建立NFS服务
- Ubuntu9.10 nfs、tftp安装
- Fedora 10 Rar and Unrar
- Active Lookup Transformation – Learn its usage and configuration steps
- Quartz学习之Lesson10-Configuration, Resource Usage and SchedulerFactory
- fedora 10启动nfs
- ubuntu9.10 Install ncurses (ncurses-devel) and try again 问题
- Scp Usage and rsync usage
- NOT EXISTS替代NOT IN EXISTS替换DISTINCT 识别‘低效执行’的SQL语句
- pl/sql控制结构(一)
- 管理学十大经典定理
- 用 PHP 读取文件的正确方法
- js中replace的用法
- NFS configuration and usage note (in Ubuntu9.10 and Fedora 10 )
- 在 Windows 窗体 DataGridView 单元格中承载控件
- 算法的独家记忆--快速排序
- POJ--2142[The Balance] 扩展欧几里德
- 利用List来实现动态的数组。
- Thread-Specific Storage
- Oracle认证SQLcodeoracle日期函数集锦
- CreateIoCompletionPort和完成端口
- POJ--2142[The Balance] 扩展欧几里德