Pages

Wednesday, 2 November 2016

January, 2012 A8-R4: BASICS OF OS, UNIX AND SHELL PROGRAMMING

January, 2012
A8-R4: BASICS OF OS, UNIX AND SHELL PROGRAMMING

PART ONE
(Answer all the questions)

1. Each question below gives a multiple choice of answers. Choose the most appropriate one and enter in the “tear-off” answer sheet attached to the question paper, following instructions therein. (1x10)
1.1 What operating system was Linux designed to "resemble somewhat"?
A) Minix
B) Windows
C) System V
D) Vunix
1.2 Which of the following is not a Linux boot loader?
A) Lilo
B) Syslinux
C) Grub
D) None of the above

1.3 External applications called ________ provide policy for the visual appearance.
A) Tiling Window Manager
B) Compositing Window Manager
C) X Window System
D) X Window Manager
1.4 DOS was the first widely-installed operating system for personal computers. What does DOS
stand for?
A) Digital Operating System
B) Disk Operating System
C) Desktop Operating System
D) It is an abbreviation of the word "doors".
1.5 ________ runs on computer hardware and serve as platform for other software to run on
A) Operating system
B) Application Software
C) System Software
D) All of the above
A8-R4 Page 2 of 5 January, 2012
1.6 When looking at the /etc/passwd file, you notice that all the password fields contain 'x'. What
does this mean?
A) That the password is encrypted.
B) That you are using shadow password file.
C) That all passwords are blank.
D) That all passwords have expired.
1.7 Which of the following command would you use to cleanly restart a Linux machine?
A) init 5
B) init 6
C) init 0
D) shutdown –h
1.8 After the kernel is loaded, it calls the ________ daemon which is responsible for creating new
processes.
A) inittab
B) sys.conf
C) init
D) syslog
1.9 You want to know how much space is being occupied by your user's home directories. Which
of the following will provide you with this information?
A) du -l /home
B) du -b /home
C) du -m /home
D) du -c /home
1.10 Using command substitution, how would you display the value of the present working
directory?
A) echo $(pwd)
B) echo pwd
C) $pwd
D) pwd | echo

2. Each statement below is either TRUE or FALSE. Choose the most appropriate one and ENTER in the “tear-off” sheet attached to the question paper, following instructions therein. (1x10)
2.1 Linux is a multitasking Operating System.
2.2 In Unix, ctrl-z will suspend a job and put it in the background.
2.3 Relative pathnames begin with a slash.
2.4 While copying a file if the destination does not exist, the copy is renamed.
2.5 Users can read, write or execute each others' files without permission.
2.6 echo $SHELL will display the name of your shell.
2.7 Server address cannot be specified by DHCP.
2.8 Unix filenames are case sensitive.
2.9 Scheduling priority does not determine access to the CPU.
2.10 Aliases let you create shortcuts to commands.

3. Match words and phrases in column X with the closest related meaning/word(s)/phrase(s) in column Y. Enter your selection in the “tear-off” answer sheet attached to the question paper, following instructions therein. (1x10)
                              X                                             Y
3.1 Process                                        A. The process is dead but have not been removed from the
                                                              process table.
3.2 Inode                                           B. Translates hostnames to network addresses.
3.3 Sort – u                                        C. A collection of virtual memory space, code, data, and system
resources.
3.4 Zombie                                       D. Run levels used by Linux
3.5 Touch                                         E. The data structure used to maintain file identification.
3.6 Symbolic                                    F. Connects processes with other processes.
3.7 Spooling                                    G. The system reads information from sensors and must respond
                                                              within a fixed amount of time to ensure correct performance.
3.8 DNS                                           H. Link points to another file.
3.9 Real Time                                   I. Removes duplicate lines from input.
3.10 Pipe                                          J. Exit from a process execution.
                                                        K. It uses the disk as a large buffer for outputting data to line
                                                               printers and other devices.
                                                       L. Change File Access Permissions.
                                                       M. Create empty files or update file timestamps.

4. Each statement below has a blank space to fit one of the word(s) or phrase(s) in the list below. Enter your choice in the “tear-off” answer sheet attached to the question paper,following instructions therein. (1x10)

A. Swapping                             B. cat                                            C. touch
D. tar                                         E. Open Source                            F. User Variable
G. Grep                                     H. bc                                              I. Wait
J. Thread                                   K. gpasswd -r                                 L. Top
M. Fork

4.1 ________ is a simple calculator.
4.2 System call to create a new process ________.
4.3 ________ is stream of executable code within process.
4.4 ________ allows each program in turn to use the memory.
4.5 To create or view a file in Linux, use ________.
4.6 Command used to remove the password assigned to a group ________.
4.7 Both archiving and un-archiving are accomplished with ________.
4.8 The ________ utility can be used to list the priority of a running process.
4.9 A ________, is one that you can create by naming it and then assign it a value.
4.10 Freedom to distribute software and source code ________.

PART TWO
(Answer any FOUR questions)
5.
a) Describe in detail the boot process of any Linux system.
b) How does the inode map to data block of a file?
c) What is a page fault and when does it occur?
(5+6+4)
6.
a) Explain /etc/shadow file used under Linux or UNIX?
b) Describe how would you find files in Linux using 'find' command.
c) How would you use head and tail in a pipeline to display lines 25 through 75 of a file?
d) Give a brief overview of “The X Window System Architecture”.
(5+3+3+4)
7.
a) Write shell script to convert file names from UPPERCASE to lowercase file names or vice
versa.
b) What does the command “$who | sort –logfile > newfile” do?
c) What are some of the improvements of Vim over Vi?
d) What is the difference between a 'thread' and a 'process'?
(6+3+3+3)
8.
a) Explain how would you schedule a task using cron? Also explain the format of cron table.
b) Explain kill() and its possible return values.
c) What is DHCP? How to exclude an ip address in DHCP? Give an example.
(6+5+4)
9.
a) List any five system calls used for process management.
b) How can files be Archived and Compressed in Linux?
c) Explain the steps that a shell follows while processing a command.
(5+5+5)

Download PDF

Next Set

No comments:

Post a Comment