VTU - B.E B.Tech - 2019 - 3rd Semester - July - CBCS 17 Scheme - CSE - 17CS35 UNIX and Shell Programming
VTU - B.E B.Tech - 2019 - 3rd Semester - July - CBCS 17 Scheme - CSE - 17CS35 UNIX and Shell Programming
com
17CS35
—
Third Semester B.E. Degree Examination, June/July 2019
UNIX and Shell Programming
Module-1
--..- 1 a. With a neat diagram, explain the architecture of UNIX operating system. (08 Marks)
b. Differentiate between internal and external commands in UNIX with suitable examples.
-0 (05 Marks)
cizt c. Write down the key combinations for managing the non-uniform behavior of key board and
w3 terminal for the following :
u
to ,-_,-
u
cu g2
.– o
_ ..... OR
r.c
,,,,,, 4F4
O-Cr 2 a. Explain the salient features of UNIX operating system. (08 Marks)
ke
L) a)
i., b. Differentiate between 'more' and 'less' page programs in UNIX. (04 Marks)
7-4 a
c. List and describe the mandatory and optional sections of man page in UNIX operating
an
C; -a
to
ct 0
...
-,i 8
C,3 system. (08 Marks)
tR
33
5'
irs
- a 71 Module-2
>,
.F
1. ....2
3 a. Illustrate with a neat diagram typical UNIX file system and explain different types of fi les
w
.-. 8
0.
O 0.a.
supported in UNIX.
w
(08 Marks)
w
g b. Assume you are in /home/Kumar, which of these commands will work when executed in
-e _2 sequence? Explain the proper reasons.
..?:-ti=.
gt_.' „,
'--: mkdir alb/c --> mkdir a a/b
=0 — -0 mkdir a a/b a/b/c -+ rmdir a/b/c --> rmdir a alb -> mkdir alp a/q a/p/r
• ,,-, Draw the final tree structure for directory 'a'. (07 Marks)
to 0
r..-. to
— ::: c. Explain the following commands with an example. i) cd ii) pwd iv) rmdir v) we. (05 Marks)
15 '471
a.2
E>
(:)
c.J OR
8-" .',--- 4 a. Which command is used for listing file attributes? Explain the significance of each field in
.._; rsi the output. (08 Marks)
Important Note
17CS35
Module-3
5 a. Explain the three modes of vi. Indicate clearly how can you switch form one mode to
another. Explain the following input mode commands : i 1, a A, r, R, o, 0, s, S. (10 Marks)
,
OR
6 a. With suitable examples, explain the `grep' command with its various options. (06 Marks)
b. Briefly explain Basic Regular Expression (BRE) and Extended Regular Expression (ERE)
metacharacters. (10 Marks)
c. Write a regular expression to match the following i) a decimal number which is non negative
and floating point number ii) A valid 'C' variable. (04 Marks)
Module 4 -
7 a. Explain the following commands with an example for each. i) head ii) tail iii) cut iv) paste.
(08 Marks)
b. What is shell programming? Write a shell program to create a simple calculator which can
perform basic arithmetic operations like addition, subtraction, multiplication or division,
om
OR
an
8 a. Write a shell program to get the following details of the student. Name, age, USN and
tR
gender. Output all the details to the terminal. And also output whether the student is eligible
irs
(04 Marks)
c. Write and explain the syntax of 'while' and 'for' loops in shell programming.
w
(08 Marks)
w
w
Module 5 -
9 a. Write a Peri script to determine whether the given year is a leap year or not. (08 Marks)
h. What is the difference between a job and a process? How do you i) suspend the foreground
job ii) move a suspended job to the background iii) bring back a suspended job to the
foreground? (06 Marks)
c. Explain the mechanism of process creation. (06 Marks)
OR
10 a. Explain the following string handling functions of PERL with example :
i) length ii) index iii) substr iv) reverse. (08 Marks)
b. Explain the following commands :
i) at cron iii) nice iv) nohup. (08 Marks)
c. With suitable examples, explain 'split' and 'join' functions in PERL. (04 Marks)
**** *
of 2
2
www.FirstRanker.com CW.(00 1
.I.RRAR y