JNTU Previous Papers-B.Tech-Unix And Shell Programming-November 2008

JNTU  B.Tech I Semester Regular Examinations, November 2008

UNIX AND SHELL PROGRAMMING

( Common to Computer Science & Engineering and Information

Technology)

SET-1

 

 

1. (a) Why unix commands are simpler rather than complex tasks.

(b) Describe the escaping sequencing characters in unix.

 

2. What would be the effect of the following commands:

(a) mail user1 user2 < myprog.c

(b) wall

(c) grep ‘rao$’ xyz

(d) cut -f1,3 file1

(e) news

(f) finger -i

(g) pg xyz

(h) uniq < xyz.

 

3. (a) What do the following UNIX system variables signify?

i. HOME

ii. PS1

iii. PATH

iv. TERM

v. MAILCHECK.

(b) How does shell executes external commands?

 

4. (a) Using sed, how do you convert files with toggle characters, like +this+, to

look like [i]this[/i]?

(b) Using sed, how do you perform a case-insensitive search.

 

5. (a) Explain about expressions in awk shell script in detail.

(b) Explain the commands in C shell program with examples.

 

6. (a) Write short notes on basic korn shell statements.

(b) Write short notes on relation expression patterns of korn shell.

 

7. (a) Use a grep command and check its exit status. When is its result zero? When

it is non zero? Check both cases.

 

(b) Use a sed command and check its exit status. When is it result zero? When

it is non zero? Check both cases.

 

8. (a) What is the difference between symlink and ulink?

(b) Write the syntax for the following System Calls:

i. Create

ii. Read

iii. Write

iv. Open.

 

 

Leave a Comment