当前位置:网站首页>NFS mount
NFS mount
2022-06-30 06:45:00 【Running on the road】
1、 install NFS service
sudo apt-get install nfs-kernel-server
2、 Modify the configuration and add a shared directory
sudo vim /etc/exports
add to /home/ubuntu/catkin_ws Catalog
# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients. See exports(5).
#
# Example for NFSv2 and NFSv3:
# /srv/homes hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check)
#
# Example for NFSv4:
# /srv/nfs4 gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check)
# /srv/nfs4/homes gss/krb5i(rw,sync,no_subtree_check)
#
/home/ubuntu/catkin_ws
3、 Set permissions and modify file users for the mounted directory
sudo chmod -R 777 /home/ubuntu/catkin_ws
sudo chown -R 777 /home/ubuntu/catkin_ws
“-R” The scope of the command includes the folder and all its subfolders
4、 start-up nfs service
start-up
sudo /etc/init.d/nfs-kernel-server start
restart
sudo /etc/init.d/nfs-kernel-server restart
5、 mount
sudo[ Space ]mount[ Space ]-t[ empty
grid ]nfs [ Space ][ Server side IP Address ][ The colon ][ The path of the server to mount the file ][ Space ][ Mount to client
The path of ]
sudo mount -t nfs 192.168.43.214:/home/ubuntu/catkin_ws /mnt
The following sentence can be used when mounting on the server is unsuccessful
sudo mount -t nfs -o nolock,nfsvers=3,vers=3 192.168.43.214:/home/ubuntu/catkin_ws /mnt
6、 View the mount
df -h
[email protected]:~$ df -h
Filesystem Size Used Avail Use% Mounted on
udev 1.9G 0 1.9G 0% /dev
tmpfs 383M 7.5M 375M 2% /run
/dev/mmcblk0p2 15G 6.3G 7.4G 46% /
tmpfs 1.9G 0 1.9G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 1.9G 0 1.9G 0% /sys/fs/cgroup
/dev/mmcblk0p1 253M 78M 175M 31% /boot/firmware
tmpfs 383M 16K 383M 1% /run/user/120
tmpfs 383M 0 383M 0% /run/user/1000
192.168.43.214:/home/ubuntu/catkin_ws 15G 6.3G 7.4G 46% /mnt
7、 install NFS client
sudo apt-get install nfs-common
8、 problem 1:nfs Access denied “mount.nfs: access denied by server while mounting 192.168.0.100:/home/wheeltec/catkin_ws”
resolvent :
There are many web pages , With permission to modify . Modify the shared directory and the mounted directory 777 Authority . There are instructions that will restart but are different . link 1、 link 2
When I encountered this problem, I modified the permissions and configuration files above , After the reboot, the mount succeeds
sudo service nfs-kernel-server restart
边栏推荐
猜你喜欢

随机网络,无标度网络,小世界网络以及NS小世界的性能对比matlab仿真

Pay attention to this live broadcast and learn about the path to achieve the dual carbon goal of the energy industry

C language: exercise 3

It turns out that you are such an array. You have finally learned

0基础转行软件测试,如何实现月薪9.5k+

史上最全一句话木马

Jgaurora A8 configuration file

1.2 (supplementary)

Rhcsa day 1

HuaWei满级大牛首次分享出这份598页网络协议全彩手册
随机推荐
File transfer protocol, FTP file sharing server
RT thread application
Install the components corresponding to setup
Introduction to neural networks
As function memo
1.3 - 码制
Idea add database
SOC_AHB_SD_IF
RT thread Kernel Implementation (V): timer
Suggestion: use tools:overrideLibrary
RT thread Kernel Implementation (VI): time slice
1.3 - Code System
C language final experiment report (student achievement management system) source code
InnoDB engine in MySQL
1.9 - Cache
1.8 - 多级存储
Joseph problem C language
华泰炒股安全吗?我想网上开户。
Rhcsa day 3
Static routing job