Unix/Lunux/Linux Mcqs Questions Set 5 Sample Test,Sample questions

Question:
Ctrl-Z key combination

1.generates a SIGINT signal

2.stops the process running in the shell

3.kills the process running in the shell

4.generates a SIGINT signal & kills the process running in the shell

Posted Date:-2021-06-28 16:25:18


Question:
Functions improves the shells programmability significantly, because

1.when we invoke a function, it is already in the shells memory, therefore a function runs faster than seperate scripts

2.function will not provides a piece of code for repetative tasks

3.all of the mentioned

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
How do you remove duplicate lines from the file foo using uniq?

1.sort foo | uniq –u

2.sort -u foo | uniq -d

3.sort foo | uniq –c

4.sort foo | uniq –I

Posted Date:-2021-06-28 16:25:18


Question:
If a and b are 2 variables then the meaning of a<<=b is

1.b = a << b

2.a = a << b

3.b = b << a

4.a = a << b

Posted Date:-2021-06-28 16:25:18


Question:
In the shell, by default, all variables are considered and stored as

1.string

2.integer

3.character

4.float

Posted Date:-2021-06-28 16:25:18


Question:
kill %s command will

1.terminate the job whose command line starts with s

2.terminate the last job

3.terminate the first job

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Parameters can be passed to a function

1.by using the parameter variables $1, $2, $3…….

2.by using the environment variables

3.by using the parameter & environment variables

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
stty tostop  command will

1.stop all jobs running in the shell

2.stop background jobs if they try to send output to the terminal

3.this is not a valid command

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The ‘logout’ built in command is used to

1.shutdown the computer

2.logoff of the computer

3.logout the current user

4.to exit the current shell

Posted Date:-2021-06-28 16:25:18


Question:
The command ‘compgen -c’ shows

1.all variable names

2.all system wide aliases

3.full list of all commands

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The command ‘disown -r’

1.removes all jobs

2.removes all running jobs

3.marks jobs to not receive SIGHUP when bash exits

4.marks all jobs

Posted Date:-2021-06-28 16:25:18


Question:
The command ‘enable -n ‘

1.enables the specified built-in command

2.disables the specified built-in command

3.print the status of the command

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The command hash

1.manages a internal hash table

2.find and remember the full path name of the specified command

3.displays used command names and the number of hits

4.all of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The command ulimit

1.set a limit on specified resource for system users

2.set/show process resource limit

3.set a limit on specified resource for system users & set/show process resource limit

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The command umask -S

1.prints the current mask using symbolic notation

2.prints the current mask using octal numbers

3.sets the mask to 000

4.sets the mask to 777

Posted Date:-2021-06-28 16:25:18


Question:
The keyword local is used

1.to define a variable within a function for its local scope

2.to redefine any global variable

3.this is not a valid keyword

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
The mapfile command

1.reads lines of standard input and assigns each to the element of an indexed array

2.reads lines of standard output file

3.reads lines of standard error file

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
This set of Linux / Unix questions and answers focuses on Command History and Job Control in Bash Shell programming    fc stands for

1.find command

2.fix command

3. both find & fix command

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
To redefine a variable, it can be removed from the list of variables by using the command

1.unset

2.delete

3.remove

4.clear

Posted Date:-2021-06-28 16:25:18


Question:
What is job number?

1.same as PID

2.a unique number, assigned to each job in shell

3.same as PID and a unique number, assigned to each job in shell

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
What is the command that can print lines of first file matching with second file?

1.printline

2.cmp

3.com

4.comm

Posted Date:-2021-06-28 16:25:18


Question:
What is the function of bind command in bash shell?

1.defining new macros

2.defining new key bindings for existing commands

3.dumping the installed key bindings

4.all of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
When the return value of any function is not specified within the function, what function returns?

1.nothing

2.exit status of the last command executed

3.0

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which built-in command performs integer arithmetic in bash shell?

1.let

2.get

3.set

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which character to use to escape meaning of special characters in search operations?

1.[].

2.^

3..'

Posted Date:-2021-06-28 16:25:18


Question:
Which command allows to view the current jobs being handled by the shell?

1.jobs

2.view

3.show

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command brings a background job into the foreground?

1.fg

2.bg

3. jobs %1

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command can create environment variable?

1.export

2.set

3.read

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command concatenate the specified argument into a single command, then execute the command?

1.fc

2.eval

3.exec

4.getopts

Posted Date:-2021-06-28 16:25:18


Question:
Which command identifies the resource of a command?

1.type

2.typeset

3.select

4.source

Posted Date:-2021-06-28 16:25:18


Question:
Which command is used to reexecute the previous command?

1.!!

2.!cat

3.!3

4.!$

Posted Date:-2021-06-28 16:25:18


Question:
Which command prints the accumulated user and system times for processes run from the shell?

1.time

2.times

3.both time and times

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command prints the directory stack?

1.cd

2.dirs

3.popd

4.pushd

Posted Date:-2021-06-28 16:25:18


Question:
Which command puts a script to sleep untill a signal is recieved?

1.sleep

2.suspend

3.disown

4.break

Posted Date:-2021-06-28 16:25:18


Question:
Which command reads user input from the terminal and assign this value to a variable name?

1.read

2.get

3.declare

4.set

Posted Date:-2021-06-28 16:25:18


Question:
Which command removes a directory from directory stack?

1.dirs

2.popd

3.pushd

4.rm

Posted Date:-2021-06-28 16:25:18


Question:
Which command runs the shell built-in command command with the given argument?

1.builtin

2.caller

3.there is no command present for this purpose

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command sets up shorthand for command or command line?

1.set

2.alias

3.new

4.echo

Posted Date:-2021-06-28 16:25:18


Question:
Which command terminates a running process by name of the process?

1.kill

2.pkill

3.killall

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which command wait for the specified process to complete and return the exit status?

1.sleep

2.wait

3.delay

4.stop

Posted Date:-2021-06-28 16:25:18


Question:
Which expression use the value of the enclosed arithmetic expression?

1.$(())

2.$()

3.${}

4.$[].

Posted Date:-2021-06-28 16:25:18


Question:
Which of the following command provides the list of the functions defined in the login session?

1.declare -f

2.declare -F

3.both declare -f and -F

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which one of the following is bitwise exclusive or operator?

1.^=

2.|=

3.!=

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which one of the following is not a valid operator in bash shell?

1.||

2.~

3.=<<

4. -=

Posted Date:-2021-06-28 16:25:18


Question:
Which one of the following is not a valid shell variable?

1._san

2.san_2

3._san_2

4.2_san

Posted Date:-2021-06-28 16:25:18


Question:
Which one of the following is not correct about job control in bash shell?

1.it is the ability to stop and resume any process running in shell at a later point

2.user employs this facility via an interactive interface supplied by the kernels terminal driver and bash

3. it is the ability to create any process

4.none of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which one of the following statement is true about variables in shell?

1.variables do not require declaration before assigning value to them

2.variables are case sensitive

3.to extract the contents of a variable, we have to provide the variable a preceding $

4.all of the mentioned

Posted Date:-2021-06-28 16:25:18


Question:
Which option of the command cd use the actual filesystem path for cd.. and the value of pwd?

1.-l

2.-L

3.-p

4. -P

Posted Date:-2021-06-28 16:25:18


Question:
Which option of the kill command sends the given signal name to the specified process?

1.-l

2.-n

3.-s

4.-a

Posted Date:-2021-06-28 16:25:18


Question:
Which statement resumes the next iteration of a for, while, select, or untill loop?

1.continue

2.break

3.complete

4.command

Posted Date:-2021-06-28 16:25:18


More MCQS

  1. Unix MCQS Set 1
  2. Unix MCQS Set 2
  3. Unix MCQS Set 3
  4. Unix MCQS Set 4
  5. Linux Mcqs Questions Set 1
  6. Linux Mcqs Questions Set 2
  7. Linux Mcqs Questions Set 3
  8. Linux Mcqs Questions Set 4
  9. Linux Mcqs Questions Set 5
  10. Linux Mcqs Questions Set 6
  11. Linux Mcqs Questions Set 7
  12. Linux Mcqs Questions Set 8
  13. Linux Mcqs Questions Set 9
  14. Linux Mcqs Questions Set 10
  15. Linux Mcqs Questions Set 11
  16. Linux Mcqs Questions Set 12
  17. Linux Mcqs Questions Set 13
  18. Linux Mcqs Questions Set 14
  19. Unix MCQ Set 01
  20. Unix MCQ Set 02
  21. UNIX SYSTEM Mcq
  22. Unix MCQ
  23. Linux MCQ Unit 1
  24. Linux MCQ Unit 2
  25. LINUX MCQ QUESTIONS AND ANSWER
  26. Linux File Permissions MCQ Questions Answers
  27. Linux Administration MCQ question and answer
  28. Linux MCQ QUESTIONS AND ANSWER
Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!