Blame
Date:
Fri Dec 17 14:25:01 2021 UTC
Message:
Import sources
01
2021-12-17
jrmu
================================================================================
02
2021-12-17
jrmu
03
2021-12-17
jrmu
Shell Prompt
04
2021-12-17
jrmu
05
2021-12-17
jrmu
When you first login, you should see something like below:
06
2021-12-17
jrmu
07
2021-12-17
jrmu
username$
08
2021-12-17
jrmu
09
2021-12-17
jrmu
This is a shell prompt that will accept your input. We are using the Korn
10
2021-12-17
jrmu
Shell (ksh). This shell is how we interact with the computer. This environment
11
2021-12-17
jrmu
is often called the "command line" because you type commands to the computer and
12
2021-12-17
jrmu
it responds to you. We don't use mice or touchscreens much. Once you get used
13
2021-12-17
jrmu
to it, you will come to like it.
14
2021-12-17
jrmu
15
2021-12-17
jrmu
If you see a # dollar sign instead, it means you are logged in as the superuser
16
2021-12-17
jrmu
(root). If you are root, you have system administrator powers. The superuser
17
2021-12-17
jrmu
has total control over the computer, whereas a normal user has limited powers.
18
2021-12-17
jrmu
In UNIX, every command must be run by a user. The $ sign you see at the
19
2021-12-17
jrmu
beginning of the shell prompt means you are running as normal user.
20
2021-12-17
jrmu
21
2021-12-17
jrmu
Note that all of our commands begin with either a $ dollar sign or # pound
22
2021-12-17
jrmu
symbol:
23
2021-12-17
jrmu
24
2021-12-17
jrmu
$ less .shell
25
2021-12-17
jrmu
# whoami
26
2021-12-17
jrmu
27
2021-12-17
jrmu
We don't actually type the $ dollar sign or # pound symbol. The $ dollar sign
28
2021-12-17
jrmu
means to run the command as a normal user, and the # pound symbol means to
29
2021-12-17
jrmu
run the command as superuser (root).
30
2021-12-17
jrmu
31
2021-12-17
jrmu
If you type commands that don't exist:
32
2021-12-17
jrmu
33
2021-12-17
jrmu
username$ ircnow of the users by the users for the users
34
2021-12-17
jrmu
ksh: ircnow: not found
35
2021-12-17
jrmu
36
2021-12-17
jrmu
The shell ksh (korn shell) will tell you the command is not found.
37
2021-12-17
jrmu
38
2021-12-17
jrmu
================================================================================
39
2021-12-17
jrmu
40
2021-12-17
jrmu
Practice Some Commands
41
2021-12-17
jrmu
42
2021-12-17
jrmu
Press q to quit, then
43
2021-12-17
jrmu
44
2021-12-17
jrmu
$ less .shell
45
2021-12-17
jrmu
46
2021-12-17
jrmu
to return to this tutorial.
47
2021-12-17
jrmu
48
2021-12-17
jrmu
To find out what user you are running as, type $ whoami
49
2021-12-17
jrmu
50
2021-12-17
jrmu
To view the current date, type $ date
51
2021-12-17
jrmu
52
2021-12-17
jrmu
To view a calendar, type $ cal
53
2021-12-17
jrmu
54
2021-12-17
jrmu
To see how much space we have on our disk, type $ df
55
2021-12-17
jrmu
56
2021-12-17
jrmu
Cool Tip: If you press the up arrow key, you can scroll through your previous
57
2021-12-17
jrmu
commands. Press on the down arrow key to scroll through more recent commands.
58
2021-12-17
jrmu
You can also use the left and right arrow key to edit your previous commands.
59
2021-12-17
jrmu
To view all your old commands, type $ history
60
2021-12-17
jrmu
61
2021-12-17
jrmu
To move on to the next level, open the file .unix102.txt (note the period in
62
2021-12-17
jrmu
front):
63
2021-12-17
jrmu
64
2021-12-17
jrmu
$ less .unix102.txt
65
2021-12-17
jrmu
66
2021-12-17
jrmu
================================================================================
IRCNow