Finger command in Linux with Examples
Finger command is a user information lookup command which gives details of all the users logged in. This tool is generally used by system administrators. It provides details like login name, user name, idle time, login time, and in some cases their email address even. This tool is similar to the Pinky tool but the Pinky tool is just the lightweight version of this tool.
Installing finger User Information Lookup Tool
To install finger tool use the following commands as per your Linux distribution.
In case of Debian/Ubuntu
$sudo apt-get install finger
In case of CentOS/RedHat
$sudo yum install finger
In case of Fedora OS
$sudo dnf install finger
Working with finger User Information Lookup Tool
1. To finger or get details of a user.
$finger manav
Note: Here “manav” is the username.
As can be seen, it displays the login name, name, directory, shell, login time, email, and plan of the user.
2. To get idle status and login details of a user.
$finger -s manav
As can be seen, it displays the idle status along with the details of the user.
3. To avoid printing PGP key, plan and project details
$finger -p manav
As can be seen, it displays the login name, name, directory, shell, login time, email, but not the plan, PGP key, and project of the user.
4. To create a plan for a user.
$echo "Plan details" > ~/.plan
Now, after again using finger command it will display a plan for the user.
5. To create a project for a user.
$echo "Project details" > ~/.project
Now, after again using finger command it will display a project for the user.
6. To create a PGP key for a user.
$echo "pgpkey" > ~/.pgpkey
Now, after again using finger command it will display a PGP key for the user.
Please Login to comment...