Find Out NFS Clients Connected To My NFS Server Rumi, August 19, 2019 You can use the following commands. SSH or login into your nfs server and type the following command: netstat -an | grep nfs.server.ip:port If your nfs server IP address 192.168.1.12 and port is 2049, enter: netstat -an | grep 192.168.1.12:2049 Sample outputs: tcp 0 0 192.168.1.12:2049 192.168.1.5:757 ESTABLISHED tcp 0 0 192.168.1.12:2049 192.168.1.6:892 ESTABLISHED Where, 192.168.1.12 – NFS serer IP address 2049 – NFS server port 192.168.1.5 and 192.168.1.6 – NFS clients IP address showmount command You can to use the showmount command to see mount information for an NFS server. The following command should not be used as it may produce unreliable result (you can type this command on any one of the nfs client): showmount -a nas03 Sample outputs: All mount points on nas03: 192.168.1.101:/volume1/data 192.168.1.102:/volume1/data 192.168.1.103:/volume1/data 192.168.1.5:/volume1/data 192.168.1.6:/volume1/data Where, -a : List both the client hostname or IP address and mounted directory in host:dir format. This info should not be considered reliable. More about /var/lib/nfs/rmtab file The rmtab file is located at /var/lib/nfs/rmtab on nfs server and can be viewed using the cat command: cat /var/lib/nfs/rmtab From the rpc.mountd(8) man page: The rpc.mountd daemon registers every successful MNT request by adding an entry to the /var/lib/nfs/rmtab file. When receivng a UMNT request from an NFS client, rpc.mountd simply removes the matching entry from /var/lib/nfs/rmtab, as long as the access control list for that export allows that sender to access the export. Clients can discover the list of file systems an NFS server is currently exporting, or the list of other clients that have mounted its exports, by using the show- mount(8) command. showmount(8) uses other procedures in the NFS MOUNT protocol to report information about the servers exported file systems. Note, however, that there is little to guarantee that the contents of /var/lib/nfs/rmtab are accurate. A client may continue accessing an export even after invoking UMNT. If the client reboots without sending a UMNT request, stale entries remain for that client in /var/lib/nfs/rmtab. Src: https://www.cyberciti.biz/faq/appleosx-bsd-find-clients-connecting-to-a-nfsserver/ Related Administrations Configurations (Linux) NFS
How To Install MySQL on Debian 9 (Stretch) with version selection May 17, 2020May 17, 2020 Step 1 – Prerequisites Login to your Debian 9 system using shell access. For remote systems connect with SSH. Windows users can use Putty or other alternatives applications for SSH connection. ssh root@debian9 Run below commands to upgrade the current packages to the latest version. sudo apt update sudo apt… Read More
Bash Shellshock fix with scripts for Debian, Ubuntu, CentOS and other distros. including old October 3, 2014December 19, 2014 First check if your Bash is vulnerable, execute the following command- env x='() { :;}; echo vulnerable’ bash -c ‘echo this is a test’ If your system is vulnerable, you will see: vulnerable this is a test If your system is not vulnerable, you will see: bash: warning: x: ignoring… Read More
Build WAF with Reverse Proxy Load Balancer using Nginx November 16, 2022 Getting Started First, it is recommended to update and upgrade all your software packages to the latest version. You can update all of them by running the following command: apt update -y apt upgrade -y Once all the packages are updated, install other required packages with the following command: apt… Read More