Академический Документы
Профессиональный Документы
Культура Документы
Objectives
After completing this unit, students should be able to:
Log in and out of the system
State the structure of AIX commands
Execute basic AIX commands
Use AIX commands to communicate with other users
To Log out:
$ <ctrl-d>
(or)
$ exit
(or)
$ logout
login: _
Passwords
Creating or Changing:
$ passwd
Changing password for "team01"
team01's Old password :
team01's New password:
Enter the new password again:
$ _
Command Format
AIX commands have the following format:
command
mail -f
option(s)
newmail
argument(s)
WRONG:
1. Separation:
$ mail -f newmail
$ mail - f newmail
$ who -u
$ who-u
2. Order:
$ mail -f newmail
$ mail newmail -f
$ mail team01
$ team01 mail
$ who -u
$ -u who
3. Multiple Options:
$ who -m -u
$ who -m-u
$ who -mu
$ who -m u
4. Multiple Arguments:
$ mail team01 team02
$ mail team01team02
10:15:00
GMT
2000
January 2000
Tue
Wed
Thu
Fri
Looking at a month:
$ cal 1 2000
Sun
2
9
16
23
30
Mon
3
10
17
24
31
4
11
18
25
Looking at a year:
$ cal 2001
5
12
19
26
6
13
20
27
7
14
21
28
Sat
1
8
15
22
29
$ clear
lft0
pts/0
Sept 4 14:29
Sept 4 17:21
Sept 4 17:21
(or)
$ whoami
team01
Sending Mail
$ mail team01
Subject: Meeting
There will be a brief announcement meeting today
in room 602 at noon.
<ctrl -d>
Cc: <Enter>
$ mail team20@sys2
Subject: Don't Forget!
Don't forget about the meeting today!
<ctrl -d>
Cc: <Enter>
Receiving Mail
[YOU HAVE NEW MAIL]
$ mail
Mail [5.2 UCB] [AIX4.1]
(Delete message)
?q
(or)
$ write sarah@moon
The wall command writes to all terminals. This is useful to notify all
users of a system event:
For example:
$ wall The system will be inactive from 10 pm today.
$ talk john
mesg
The mesg command controls whether other users on the system
can send messages to you:
$ mesg n
Refuses messages
$ mesg y
Permits messages
Keyboard Tips
<Backspace>
Corrects mistakes
<Ctrl-c>
<Ctrl-d>
<Ctrl-s>
<Ctrl-q>
<Ctrl-u>
Exercise 1
Unit 2: Checkpoint
What is the correct command syntax in AIX?
$ mail newmail -f
$ mail f newmail
$ -f mail
$ mail -f newmail
What command would you use to send mail items?
_____________________________________________________
What are other commands that can be used to communicate with
other users?
_____________________________________________________
What output would you expect from the following command: cal 8?
_____________________________________________________
Which command would you use to find out when a particular user
logged in?
$ who am i
$ who
$ finger everyone
$ finger username
Summary
AIX commands can use multiple options and arguments
and must follow proper syntax rules
There are many simple, yet powerful commands such
as:
date
cal
who, who am i
finger
echo
clear
banner
wc
Communicate with other UNIX users using commands
such as mail, write, talk, and wall