The chfn (change finger) command updates a few pieces of personal information maintained by the system: real name, home telephone, office telephone, and office location, as displayed by the finger command.[21] Invoked without a username, chfn affects your account; invoked with a username (by the superuser), it affects that user. With no options, chfn will prompt you for the desired information:
# chfn Password: ******** Name [Shawn Smith]: Shawn E. Smith Office [100 Barton Hall]: Office Phone [212-555-1212]: 212-555-1234 Home Phone []:
Syntax:
# chfn [options] [username]
chfn Command Examples
1. To change the full name of the user:
# chfn -f "Mike Jackson" mike
2. To specify the office room number:
# chfn -o 107 mike
3. To specify the office phone:
# chfn -p 20123023 mike
4. To print the usage message for a user:
# chfn -u mike
Conclusion
chfn command changes the information that is stored in /etc/passwd and displayed to the finger query. With no options, chfn enters interactive mode and prompts for changes. To blank a field, enter the keyword none. Only a privileged user can change information for another user. For regular users, chfn prompts for the user’s password before making the change.