Tag: unix

Questions Related to unix

The agency that sits between the user and the UNIX system is called the

  1. logic

  2. profile

  3. shell

  4. erxc


Correct Option: C

Which command is used to count just the number of characters in a file?

  1. wc - 1

  2. wc -c

  3. wc -w

  4. wc -r


Correct Option: B
  1. :pat

  2. :pat

  3. /pat

  4. All of the above


Correct Option: D

Which of the following special shell variables is used to process number of the last background job?

  1. $!

  2. $#

  3. $0

  4. $*


Correct Option: A

Which option will be used with ps command to slow the entire command line of the process being run?

  1. -4

  2. -f

  3. -1

  4. -5


Correct Option: B

AI Explanation

To answer this question, you need to understand the options that can be used with the ps command.

Let's go through each option to understand why it is correct or incorrect:

Option A) -4 - This option is incorrect because -4 is not a valid option for the ps command.

Option B) -f - This option is correct because the -f option is used with the ps command to provide full-format listing. It displays additional information about each process, including the command line of the process being run.

Option C) -1 - This option is incorrect because -1 is not a valid option for the ps command.

Option D) -5 - This option is incorrect because -5 is not a valid option for the ps command.

The correct answer is Option B) -f. This option is correct because it provides a full-format listing, including the command line of the process being run.

Which of the following command addresses all users who are currently hooked on?

  1. write

  2. mail

  3. wall

  4. mesg


Correct Option: C