Ettus E3XX Getting Started Guide ANGRYVIPER Team
6.1.2 CentOS 7
From the host, install the necessary tools using yum:
% sudo yum install nfs-utils
1
From the host, allow NFS past SELinux
2
:
% sudo setsebool -P nfs_export_all_rw 1
% sudo setsebool -P use_nfs_home_dirs 1
From the host, allow NFS past the firewall:
% sudo firewall-cmd --permanent --zone=public --add-service=nfs
% sudo firewall-cmd --permanent --zone=public --add-port=2049/udp
% sudo firewall-cmd --permanent --zone=public --add-service=mountd
% sudo firewall-cmd --permanent --zone=public --add-service=rpc-bind
% sudo firewall-cmd --reload
Define the export by creating a new file that has the extension “exports”. If it does not have that extension, it
will be ignored. Add the following lines to that file and replace “XX.XX.XX.XX/MM” with a valid netmask for the
DHCP range that the SDR will be set to for your network (e.g. 192.168.0.0/16).
% sudo vi /etc/exports.d/user_ocpi.exports
/opt/opencpi XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt)
/home/user/ocpi_projects/core XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt)
/home/user/ocpi_projects/assets XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt)
If the file system that you are mounting is XFS, then each mount needs to have a unique fsid defined. Instead, use:
% sudo vi /etc/exports.d/user_ocpi.exports
/opt/opencpi XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt,fsid=33)
/home/user/ocpi_projects/core XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt,fsid=34)
/home/user/ocpi_projects/assets XX.XX.XX.XX/MM(rw,sync,no_root_squash,crossmnt,fsid=35)
Restart the services that have modified for the changes to take effect:
% sudo systemctl enable rpcbind
% sudo systemctl enable nfs-server
% sudo systemctl enable nfs-lock
% sudo systemctl enable nfs-idmap
% sudo systemctl restart rpcbind
% sudo systemctl restart nfs-server
% sudo systemctl restart nfs-lock
% sudo systemctl restart nfs-idmap
* Note: Some of the “enable” commands may fail based on your package selection, but should not cause any problems.
NOTE: You will need to add the ocpi.bsp.e310 project to your list of exports (in /etc/exports.d/user_ocpi.
exports).
1
nfs-utils-lib was rolled into nfs-utils starting with CentOS 7.2, if using eariler versions of CentOS 7, nfs-utils-lib will need
to be explicitly installed
2
You can use getsebool to see if these values are already set before attempting to set them. Some security to ols may interpret the
change attempt as a system attack.
11