CS5001NA Networks and Operating Systems: Week 9 Workshop

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

CS5001NA Networks and Operating Systems

Week 9 Workshop
1. Practice in using UNIX utilities:
8) Give the ls command (without options and with
Write your tasks and your observations in your log- a, d, g, l, R options) in your home, w2, w2-1, and
books. 1level3 directories. Explain for yourself the
1) Create the directory structure presented in the results received.
figure below. Use mkdir command and relative 9) Change to the w2 directory. Remove the
pathnames from your home directory. Try both: directory files w2-2, 3level-3, 4level3 and all
no option and –p option, for the command. ordinary files in them. Use the option –i of the
w9-1 1level3 rm and rmdir commands. Show that there are
not these ordinary and directory files in your file
2level3 structure.
W9
3level3
10) Change to w2-1.
Your  Display access permissions for the file file1
home w9-2 4level3 in 1level3.
directory  Remove all access permissions for this file.
2) Change to the 1level3 directory by one step using  Display access permissions for this file.
a relative pathname.
 Try to read this file using any utility (e.g.,
3) Practice in changing directories in your directory cat).
structure by one command using relative
pathnames, e.g., from 1level3 to 2level3, from  Try to write into this file using any utility
2level3 to 4level3, from 4level3 to w2, etc. Use (e.g., cat with the sign >> – append).
names of parent and child directories (‘.’ and ‘..’)  Add read and write access permissions for
as well. yourself for this file.
4) Change to 1level3 and create a text file by any  Display access permissions for this file.
tool (e.g., by cat or cal like last tutorial).  Try to read this file using any utility.
5) Copy this text file from 1level3 to 1level3 (with  Try to write into this file using any utility.
the name file1), 2level3, and to 3level3 changing
11) (Now,)
its name. Show that there are these files in
corresponding directories.  Display access permissions for 1level3.
6) Move this file to 4level3. Show that there is this  Remove all access permissions for the
file in 4level3 and there is not in 1level3. 1level3 directory.
7) Print the following texts each in one echo or  Display access permissions for 1level3.
print command:  Try to read a file from 1level3 using any
 Hello! I can do it utility.
 5 > (20: 8) < (30 * 2)  Try to put a file into 1level3 using any utility.
 Line 1  Try to search in 1level3 using any command
Line 2 (e.g., the ls command).
a-b, A-B, –, +, <, >, #, $, %, &.  Add read, write, and execute access
permissions for yourself for the 1level3
directory.
 Display access permissions for 1level3.
 Try to read a file from 1level3 using any
utility.
 Try to put a file into 1level3 using any utility.
 Try to search in 1level3 using any command
(e.g., the ls command).

You might also like