Professional Documents
Culture Documents
2. Enter these commands at the U !" prompt# and try to interpret the output. As$ %uestions and don&t 'e a(raid to experiment (as a normal user you cannot do much harm): echo hello world passwd date hostname arch uname a dmesg ) more (you may need to press % to %uit)
'c l (type %uit or press 0trld to %uit) echo .12 ) 'c l yes please (you may need to press 0trlc to %uit)
history
Exercise : 2 3ry the (ollowing command se%uence: cd pwd ls al cd . pwd (where did that get you/) cd .. pwd ls al cd .. ls al pwd (what happens now) cd 4etc ls al )more cat passwd cd pwd (1) (2)
(5)
2. 0ontinue to explore the (ilesystem tree using cd# ls# pwd and cat. Loo$ in 4'in#
(2)
(5) (2)
(.)
(7)
(-)
(8)
(,)
8. 6hat is the di((erence 'etween listing the contents o( directory play with ls l and ls L/
,. 0reate a (ile called hello.txt that contains the words *hello world*
11. 6hat is the output o( the command: echo <con#pre=<sent#(er=<s#ed=/ ow# (rom your home directory# copy 4etc4passwd and 4etc4group into your home directory in one command.
12. >till in your home directory# copy the entire directory play to a directory called wor$.
15. ;elete the wor$ directory and its contents with one command.
12. Experiment with the options on the ls command. 6hat do the d# i# ? and @ options do/
1.. Apply these commands and chec$ their output: sort A(ilenameB ) uni%# sort A(ilenameB ) uni% Cc ) sort Cnr.