wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

shell lab

Total questions: 20

Worksheet time: 10mins

Name
Class
Date
1.

What is a shell script?

a)

group of commands

b)

a file containing a series of commands

c)

group of functions

d)

a file containing special symbols

2.

Which command is used to remove a file?

a)

remove

b)

del

c)

rm

d)

mv

3.

The following command can list out all the current active logins.

a)

A - whoami

b)

B - who am i

c)

C - who

d)

D - None of the above.

4.

In a system, if 5 people are currently using the vi editor. then the number of corresponding processes will be

a)

1

b)

5

c)

2

d)

0

5.

The mv command changes

a)

Only the directory entry

b)

Only the directory entry and i-node

c)

Only the i-node number

d)

None of the above

6.

Unix is a

a)

Single User, Single tasking OS

b)

Single User, Multi-tasking OS

c)

Multi-User, Multi- tasking OS

d)

None

7.

Which command is used to create a file

a)

ls

b)

cat

c)

vi

d)

lyrix

8.

Which of the Linux command-line commands listed below is used for directory traversal/navigation?

a)

change

b)

cd

c)

cdc

d)

ps

9.

What command to check/see current working directory?

a)

who

b)

pwd

c)

where

d)

catch

10.

Which of the following commands in Linux is used to display information about files and directories contained within the current working directory?

a)

ls

b)

sl

c)

show

d)

None of these

11.

What is the command to list hidden files & directory?

a)

ls -l

b)

ls -a

c)

ls

d)

None of these

12.

Which of the following commands allows for moving one level up in Linux directory tree?

a)

cd -

b)

cd /

c)

cd --

d)

cd ~

13.

Which of the answers listed below refers to a command used for invoking a text editor in Unix-like operating systems?

a)

vi

b)

edit

c)

notepad

d)

none of these

14.

Which of the following key combinations allows to terminate the current process in Linux shell?

a)

Ctrl + A

b)

Ctrl + C

c)

Ctrl + L

d)

Ctrl + E

15.

For the shell built in commands, the execution speed is

a)

Low

b)

High

c)

Medium

16.

To find out what your path is, at the Unix shell prompt________

a)

$echo PATH

b)

$echo $path

c)

$echo $PATH

d)

none of the above

17.

___________runs a single command with root privileges

a)

su

b)

sudo

c)

cat

d)

path

18.

Which command is used for making the scripts interactive?

a)

a) ip

b)

b) input

c)

c) read

d)

d) write

19.

change permission of a file to rw-r--r-x?

a)

chmod 546 file

b)

chmod 642 file

c)

chmod 645 file

d)

chmod 655 file

20.
Which meta character takes output of first command as input of second command?
a)
Multiple Choice
b)
;
c)
|
d)
||