Hello World,
We have a software repository server in our environment which we use as an NFS server.
Now this has been going on well before I was hired. Now, I observed many users not unmounting the NFS resources after their use. I ran showmount and it showed 513 current sessions.
Is there a way I could know the idle clients (i.e., which haven't been using the mounted NFS resources)?
I thought of a solution - I would automate a script in which I be unmounting all the NFS directories using ssh. So, if the client is still using, the unmount would automatically be declined.
The problem here is I need to enter the password (and even type 'yes' to save RSA key fingerprint) for each of the 513 attempts. Is there a way to automate this? I had tried 'sshpass' but it completely fails.
Could someone help me complete my script? Or this there a better way to automate remote unmounting (no nfs restart/reload please)?