03-26-2002
who and finger
Yes, who will tell you a lot. You can also use the "finger" command to give different info on all users on the box. If you do a finger <user name> it will pull data from the /etc/passwd file if there is any info in the GECOS field ( user info ) like real name, phone number, location etc... .
Do a "man" on both of these to find out more.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
can someone tell me a shell-script to convert an older version of a file with the current one? (1 Reply)
Discussion started by: deeptia
1 Replies
2. UNIX for Dummies Questions & Answers
Hi There,
This is more a question for the 'mainframers' of old.
I need a control structure (AIX) very similar to "GDG" files (Generation data group) as found on OS/390 to control versions of files.
Specific files have specific needs, some need to be kept for 5 versions, some for 30 and... (0 Replies)
Discussion started by: Bizcut
0 Replies
3. UNIX for Advanced & Expert Users
Hi,
I have a c file in my repository. We are using RCS(Revision Control System) to control and manage the versions. I need to find
1. Difference between the current version with a different version
2. Difference between any two different versions of a file. Ex Difference between 1.14 and... (1 Reply)
Discussion started by: kelangovan
1 Replies
4. Shell Programming and Scripting
Hi ,
I want to write a FTP Script which checks the No of Vesions of the files in Archive Dir and if count >= 8 Delete the oldest file from the Archive Dir and if the count is <= 8 Move the file to the Archive Dir with a CurrentDate concatenation and FTP the file to the FTP directory and send... (1 Reply)
Discussion started by: kailash.jadhav
1 Replies
5. Shell Programming and Scripting
I am developing a script to maintain 'n' number of versions of a file. The script will take a filename as a parameter and the number of versions to maintain. This basically does something like a FIFO. Here is what I developed. But something is not right. I have attached the script. Can u pls help... (2 Replies)
Discussion started by: vskr72
2 Replies
6. Shell Programming and Scripting
Hi All,
I have a difficult problem (at least for me) and need your help.
Situation is like this, there are a lot of files in a lot of folders and some of them files are just versions of the same file saved by careful users . Once every few months I have to clean up and keep the last version of... (2 Replies)
Discussion started by: mihaicris
2 Replies
7. Shell Programming and Scripting
need a shell script for the following requirement
how to generate 5 versions of a file in a folder
after generating them in a folder i want to maintian the past 2 versions of the file in the folder and i have to delete the the remaining.
for example if i ran the script today and tommorow... (3 Replies)
Discussion started by: hemanthsaikumar
3 Replies
8. Shell Programming and Scripting
Hello Experts,
I want to merge my local file (File1) with the changes in remote server (File1). For Example:
File1 contents are... (file @ remote server)
ABC
<blankLine>
GHI
<EOF>
I, as USER#1, have updated the contents of File1 in my local as...
ABC
DEFGhi
<blankLine>
JKL... (2 Replies)
Discussion started by: AjMyTechGroup
2 Replies
9. Shell Programming and Scripting
Hello Forum.
I have the following files in one directory:
abc_july01_2013.txt
abc_july02_2013.txt
abc_july03_2013.txt
abc_july04_2013.txt
abc_july05_2013.txt
abc_july06_2013.txt
abc_july07_2013.txt
abc_july08_2013.txt
If I want to be able to keep the last 5 versions of the file and... (4 Replies)
Discussion started by: pchang
4 Replies
10. Shell Programming and Scripting
I want to write a korn shell script to get the latest three versions for a file in the directory having lot of files with various versions (files with prefix as same but time stamp as suffix) and compress it and at the same time have to remove the remaining versions of the file (other than latest... (4 Replies)
Discussion started by: maheshbabu
4 Replies
LEARN ABOUT OPENDARWIN
chfn
CHFN(1) User Commands CHFN(1)
NAME
chfn - change real user name and information
SYNOPSIS
chfn [options] [LOGIN]
DESCRIPTION
The chfn command changes user fullname, office room number, office phone number, and home phone number information for a user's account.
This information is typically printed by finger(1) and similar programs. A normal user may only change the fields for her own account,
subject to the restrictions in /etc/login.defs. (The default configuration is to prevent users from changing their fullname.) The superuser
may change any field for any account. Additionally, only the superuser may use the -o option to change the undefined portions of the GECOS
field.
These fields must not contain any colons. Except for the other field, they should not contain any comma or equal sign. It is also
recommended to avoid non-US-ASCII characters, but this is only enforced for the phone numbers. The other field is used to store accounting
information used by other applications.
OPTIONS
The options which apply to the chfn command are:
-f, --full-name FULL_NAME
Change the user's full name.
-h, --home-phone HOME_PHONE
Change the user's home phone number.
-o, --other OTHER
Change the user's other GECOS information. This field is used to store accounting information used by other applications, and can be
changed only by a superuser.
-r, --room ROOM_NUMBER
Change the user's room number.
-R, --root CHROOT_DIR
Apply changes in the CHROOT_DIR directory and use the configuration files from the CHROOT_DIR directory.
-u, --help
Display help message and exit.
-w, --work-phone WORK_PHONE
Change the user's office phone number.
If none of the options are selected, chfn operates in an interactive fashion, prompting the user with the current values for all of the
fields. Enter the new value to change the field, or leave the line blank to use the current value. The current value is displayed between a
pair of [ ] marks. Without options, chfn prompts for the current user account.
CONFIGURATION
The following configuration variables in /etc/login.defs change the behavior of this tool:
CHFN_RESTRICT (string)
This parameter specifies which values in the gecos field of the /etc/passwd file may be changed by regular users using the chfn
program. It can be any combination of letters f, r, w, h, for Full name, Room number, Work phone, and Home phone, respectively. For
backward compatibility, yes is equivalent to rwh and no is equivalent to frwh. If not specified, only the superuser can make any
changes. The most restrictive setting is better achieved by not installing chfn SUID.
FILES
/etc/login.defs
Shadow password suite configuration.
/etc/passwd
User account information.
SEE ALSO
chsh(1), login.defs(5), passwd(5).
shadow-utils 4.5 01/25/2018 CHFN(1)