Worksheetsshell lab
Total questions: 20
Worksheet time: 10mins
What is a shell script?
group of commands
a file containing a series of commands
group of functions
a file containing special symbols
Which command is used to remove a file?
remove
del
rm
mv
The following command can list out all the current active logins.
A - whoami
B - who am i
C - who
D - None of the above.
In a system, if 5 people are currently using the vi editor. then the number of corresponding processes will be
1
5
2
0
The mv command changes
Only the directory entry
Only the directory entry and i-node
Only the i-node number
None of the above
Unix is a
Single User, Single tasking OS
Single User, Multi-tasking OS
Multi-User, Multi- tasking OS
None
Which command is used to create a file
ls
cat
vi
lyrix
Which of the Linux command-line commands listed below is used for directory traversal/navigation?
change
cd
cdc
ps
What command to check/see current working directory?
who
pwd
where
catch
Which of the following commands in Linux is used to display information about files and directories contained within the current working directory?
ls
sl
show
None of these
What is the command to list hidden files & directory?
ls -l
ls -a
ls
None of these
Which of the following commands allows for moving one level up in Linux directory tree?
cd -
cd /
cd --
cd ~
Which of the answers listed below refers to a command used for invoking a text editor in Unix-like operating systems?
vi
edit
notepad
none of these
Which of the following key combinations allows to terminate the current process in Linux shell?
Ctrl + A
Ctrl + C
Ctrl + L
Ctrl + E
For the shell built in commands, the execution speed is
Low
High
Medium
To find out what your path is, at the Unix shell prompt________
$echo PATH
$echo $path
$echo $PATH
none of the above
___________runs a single command with root privileges
su
sudo
cat
path
Which command is used for making the scripts interactive?
a) ip
b) input
c) read
d) write
change permission of a file to rw-r--r-x?
chmod 546 file
chmod 642 file
chmod 645 file
chmod 655 file
