Chapter 5
1) who
3 }cp - copy files and directories mv - move (rename) files you would just basically overwrite the file
4) apropos edit Typical editors are vim, ex, ed and gedit.
8) The which utility displays a message saying that the command you are looking for is not in the list of directories in your search path. For example,
$ which me
/usr/bin/which: no me in (/usr/bin/which: no me in
(/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/home/sam/bin)
10) Approximately 20
Unit 2
Chapter 6
1) 1.Is each of the following an absolute pathname, a relative pathname, or a simple filename?
a. milk_co
b. correspond/business/milk_co
c. /home/max
d. /home/max/literature/promo
e. ..
f. letter.0210
A: a= Directory File b= relative c= absolute d= absolute e= Hidden File or can be used for the relative parent directory f= Ordanary/Simple File
2) a. cd; b. pwd
3) If the working directory is /home/max with a subdirectory named literature, give three sets of commands you can use to create a subdirectory named classics under literature. Also give several sets of commands you can use to remove the classics directory and its contents.
A: a= mkdir /home/max/literature/classics, mkdir ~max/literature/classics, or mkdir ~/literature/classics
b= rmdir /home/max/literature/classics, rmdir ~max/literature/classics, rmdir ~/literature/classics, rm -r /home/max/literature/classics
4) The df utility displays all mounted filesystems along with information about each. Use the df utility with the –h (human-readable) option to answer the following questions.
$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hda1 1.4G 242M 1.1G 18% /
/dev/hda3 23M 11M 10M 51% /boot
/dev/hda4 1.5G 1.2G 222M 85% /home
/dev/hda7 564M 17M 518M 4% /tmp
/dev/hdc1 984M 92M 842M 10% /gc1
/dev/hdc2 16G 13G 1.9G 87% /gc2
a. How many filesystems are mounted on your Linux system?
b. Which filesystem stores your home directory?
c. Assuming that