Monday, 24 October 2016

July, 2014 A8-R4: BASICS OF OS, UNIX & SHELL PROGRAMMING

July, 2014
A8-R4: BASICS OF OS, UNIX & 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 “OMR” answer sheet supplied with the question paper, following instructions therein. (1x10)
1.1 Which one of the following is used for file system check at startup?
A) syscheck
B) check
C) fsck
D) rootchk
1.2 Which one of following is used to redirect output to a file while still redirecting to another
program?
A) tee
B) >
C) >>
D) 2>

1.3 Which one of following is used to list the hidden files of current directory?
A) ls -l
B) ls -a
C) ls -h
D) ls -f
1.4 Which one of the followings can be used to change the default access permission of file?
A) chmod
B) chwon
C) changeper
D) defaper
1.5 ________ is a home directory of root user in Unix.
A) /home/root
B) /root
C) /etc/root
D) /etc

1.6 The command which can change access time of a file.
A) touch
B) changetime
C) edit
D) timechange
1.7 Which one of the following displays process information?
A) ps
B) pi
C) procstat
D) statproc
1.8 Which is the function of UNIX kernel?
A) Adding and removing a user
B) Managing and scheduling a jobs
C) Loggin IN and loggin OUT
D) Creating file and deleting file
1.9 In Unix, to append data to an existing file ___________ symbol is used.
A) >
B) ))
C) >>
D) @
1.10 The shutdown procedure must be called in UNIX system before switching off the power
supply because
A) Otherwise the file system may become inconsistent
B) All uses must be informed the the system is being switched off
C) The power to the disk and display units myst be shut off first
D) None of the above

2. Each statement below is either TRUE or FALSE. Choose the most appropriate one and ENTER in the “OMR” answer sheet supplied with the question paper, following instructions therein. (1x10)
2.1 “unique” command removes all duplicate lines from file.
2.2 A Printer is block oriented device.
2.3 PS1 is an environment variable in UNIX.
2.4 UNIX is case sensitive operating system.
2.5 LILO is not a Linux boot loader.
2.6 “kill” command is used to send signal to process.
2.7 The /etc/inittab file contains the processes that are started when init brings up the system.
2.8 “procalter” command alters process scheduling priority.
2.9 The inode resides on disk.
2.10 “df” command prints usage of file system.

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 “OMR” answer sheet supplied with the question paper, following instructions therein. (1x10)
                              X                                                         Y
3.1 Gives short description of command.                   A. xterm
3.2 File which contains hostname to IP address         B. /etc/passwd
3.3 Graphical terminal emulation window.                C. whatis
3.4 File which stores password of users.                    D. cat
3.5 Command to list content of current directory.      E. .bashrc
3.6 Command to create a file.                                    F. su
3.7 File which will be loaded when user opens         G. /etc/hosts
 shell terminal.

3.8 Used on directories shared by group of users.  H. ls
3.9 Command to switch to root user.                      I. dir
3.10 Backup command.                                          J. /etc/shadow
                                                                                K. dl
                                                                                L. Sticky-bit
                                                                               M. cpio

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 “OMR” answer sheet supplied with the question paper,following instructions therein. (1x10)

A. chmod                         B. ENVIRON                             C. Hierarchical
D. mget                            E. download                                F. magic number
G. daemon                       H. pwd                                          I. pipe
J. star                                K. Init                                          L. PATH
M. Sticky-bit

4.1 ________ command retrieves file from the remote host.
4.2 ________ can be used to change the default access permission of file.
4.3 Only super-user can set the ________ for a file.
4.4 ________ is an environment variable in UNIX.
4.5 ________ is a background process in UNIX.
4.6 ________ command displays absolute path of current directory.
4.7 All executable files are marked with ________ at beginning.
4.8 UNIX has a ________ file organization.
4.9 ________ makes the output of one program the input to another.
4.10 ________ is a first process in UNIX.

PART TWO
(Answer any FOUR questions)
5.
a) Write a shell script which takes one number from screen and prints whether a given number
is odd or even.
b) X Windows system is responsible for graphical user interface in Linux. What are the
elements of X Window System?
c) What is a cron? Which file is associated with cron? By taking a suitable example, explain
format of file.
(3+6+6)
6.
a) Which command is used to change permission associated to File/Directories? List and
explain methods to change permission of File/Directories.
b) Explain following command with two options:
i) find
ii) mount
iii) grep
(6+9)
7.
a) The term run-level refers to a mode of operation in UNIX Operating Systems. What are
different run-level in UNIX. What is purpose of each run-level?
b) What are differences between hard link and soft link? By taking suitable example, explain
how to create hard link and soft link.
c) What are the major directories used by Unix Operating system?
(4+4+7)
8.
a) What are the Linux Characteristics which makes it different from any other OS?
b) Write a shell script which takes three numeric values for terminal and prints the largest of
three numbers and also prints the total and average.
c) What do you mean by device file? Where can you locate them? How can you find out
whether a device is block or character oriented?
(5+5+5)
9.
a) How overwriting and appending can be performed in Linux? Using suitable example, explain
how standard error can be redirected?
b) Explain advantage of compressing files. Which utility is used for compressing files in UNIX?
Describe its usage.
c) How can you make a directory that a group of users can share but cannot remove files
belonging to other users?
(5+5+5)

Download PDF

Next Set

No comments:

Post a Comment