CLI: get the df -h for the disk of the $HOME
Hi, I would like to know the free space available (and other info) for the disk of the user ($HOME) in a robust method, such as taking consideration of the file /etc/passwd which tells us where is the $HOME directory of a given user.
Thanks a lot ! |
What have you tried so far? Do you have a specific question?
|
Quote:
Well, I plan to code a bash/ksh script that would look into /etc/fstab /etc/password with the $USER and mount and some df ... likely. It will work but I would like something from linux core system (if possible)... to avoid this maybe non necessary coding, since already possible with Linux. Thanks I wish you a nice day! |
df -h ~username will automatically mount user's home if you are allowed to cd into.
|
All times are GMT -5. The time now is 01:27 PM. |