Week 8 - Graded + Practice Assignment
Week 8 - Graded + Practice Assignment
Question 1
Which of the following commands can be used to check the processor information your linux machine is
running on? [MSQ]
(a) hwinfo
(b) lshw
(c) lspci
(d) cat proc/cpuinfo
(e) cat proc/partitions
Answer
(a), (b) and (d)
Question 2
Which of the following commands can be used to print the total amount of memory(in gigabytes) available
on your linux machine? The output may or may not contain any string for unit(i.e. GB), but should print only
one number in gigabytes that is the total memory available. [MSQ]
Answer
(b) and (d)
Question 3
Which command will change the prompt string to show date, command number and current username
followed by character "@" followed by complete hostname and finally followed by the string ":$", in
the same sequence?
For example if the current username is "SC", complete hostname is "SC-HP-Probook", date today is "Tue
Mar 08" and command number is "48" the prompt string should look like
Answer
(d)
Question 4
How many times per day the below process is executed? [NAT]
Answer
1
Question 5
Select all the days the below process is executed? [NAT]
(a) Sunday
(b) Monday
(c) Tuesday
(d) Wednesday
(e) Thursday
(f) Friday
(g) Saturday
Answer
(b), (c), (d), (e), (f)
Question 6
Suppose you have to send a good morning message to everyone at 6 am in the morning everyday. Assume
the command send-good-morning will send the message to everyone. Select the job will do that.
Answer
(e)
Question 7
Every device connected to the Internet has at least one IP address which indicates where traffic has come
from. Each IP address has some associated port numbers for each transport protocol used for determining
the correct receiving application. IP addresss and Port numbers are respectively
(2) 32-bit nonnegative natural numbers and 16-bit nonnegative natural numbers
(4) 16-bit nonnegative natural numbers and 32-bit nonnegative natural numbers
Answer
(1) 32-bit nonnegative integer and 16-bit nonnegative integers
Question 8
Which command will give information on open network ports on the machine?
(a) nslookup
(b) whois
(c) wireshark
(d) netstat
Answer
(d)
Question 9
"test.tar" contains three files test1, test2 and test3. Choose the right command that will extract these files
from "test.tar". (MCQ)
(1)
(2)
(3)
(4)
Answer
3.
Question 10
$ nslookup google.com
(1) Retrieve information about a domain name such as its server and ip address.
Question 11
Match the following networing commands to its respective function.
(MCQ)
Option Function
Answer
(1) 1—>c; 2—>d; 3—>b; 4—>a; 5->e;
Question 12
Match the following options of "tar" command to their use.
Option Usage
1. x i. use gzip
Answer
(d)
Question 13
Contents of file1
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
cccccccccccccccccccccccccccccccccccc
dddddddddddddddddddddddddddddddddddd
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
ffffffffffffffffffffffffffffffffffff
Contents of file2
Wj^rofdOhZO[giJYBHMDYVoqCGfREi[MTmF`
FHWf]eaUIqJXCkLnYTmfOCVnc\ZMDdlrcp[D
`EelM]krNNB^MIJmDniBW]JlWV`k^YmGBbAV
PICXGELJh[Xmmid_fen`E\Xf]Y]kCoRkXEKD
bDfRfJmolQbTVJDVbWSfoTqODfYkaNjHKf]_
[SmrlE\\l]ZTYQeHjKJkFETO]LDhHVValIqD
Note that both file1 and file2 have same size and number of characters. Both the files are compressed using
the utility gzip to file1.gz and file2.gz respectively.
(c) The size of file1.gz will be the same as the size of file2.gz
(d) The size of file1.gz will always greater than file2.gz because file1 have simple patterns.
Answer
(b)
Question 14
Below are the contents of the file "abcdef", where each line has 36 characters.
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb
cccccccccccccccccccccccccccccccccccc
dddddddddddddddddddddddddddddddddddd
eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
ffffffffffffffffffffffffffffffffffff
What will be the size of the file in bytes when it is compressed using bzip2? [NAT]
Answer
Range: From 50 to 60
Question 15
Choose the command to list all the empty files and delete them. [MSQ]
Answer
(b), (c), (d)
Question 16
Three Hard disk drives of capacity 456 Gb, 564 Gb and 768 Gb are connected in RAID 0. What is the
equivalent storage capacity of the RAID arrangement?
(1) 456 Gb
(2) 768 Gb
(3) 1368 Gb
(4) 2304 Gb
Answer
(3) 1368 Gb
Question 17
A data centre uses old recycled small size disk drives as a cost cutting measure. The downside in using
recycled disk drives is that each drive can handle only one query at a time. Which of the following RAID
configurations should the data centre deploy to achieve better performance(read speeds) and for data and
sustain at least one disk failure without loosing data? [MSQ]
(1) RAID 0
(2) RAID 1
(3) RAID 4
(4) RAID 6
Answer
(3) and (4)
(1) 0 – 1023
(4) 0 - 65535
Answer
(2) 1024 – 49151
Problem 2
Multiple correct answers are possible for this question.
The command used to find your IP address in Ubuntu is;
(MSQ)
(1) ifconfig -a
(2) ip add
(3) give ip
(4) hostname -I
Answer
1. ifconfig -a
2. ip add
3. hostname -I
Problem 3
dig is a DNS lookup utility. Match the options of the dig command to its respective function.
(MCQ)
Option Function
Answer
1. 1—>c; 2—>d; 3—>b; 4—>a;
Problem 4
Choose the command which will print all the directories within the current directory, whose names starts
with the letter 'K' and are accessed in last two days.
Answer
(d)
Problem 5
Suppose a data centre wishes to configure 3192 * 2 Tb hard disk drives in RAID 6 (1+6) configuration. The
storage capacity of a equivalent disk drive is
(1) 3190 Tb
(2) 6364 Tb
(3) 6380 Tb
(4) 3192 Tb
Answer
(1) 3190 Tb