Operating System-Unix [3i Infotech Placement]: Sample Questions 21 - 22 of 78

Glide to success with Doorsteptutor material for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

Question 21

Edit

Describe in Detail

Essay▾

What is ‘ps’ command for?

Explanation

Undderstanding of Process Status with Ps Command
  • ‘ps’ command on linux is one of the basic commands for viewing the processes running on the system.
  • Provides a snapshot of the current processes along with detailed information like user id, cpu usage, memory usage, command name.
  • Does not display data in real time like top or htop commands.
  • Simpler in features and output but provides essential process management tool.

Syntax:

ps [options]

  • Related commands include pgrep that supports searching for processes and pkill that kills processes based on a search.

Question 22

Edit

Describe in Detail

Essay▾

What are the process states in Unix?

Explanation

Understanding of Process State
  • Running:
    • Process is either running or ready to run.
  • Interruptible:
    • A blocked state of a process waiting for an event or signal from another process.
  • Uninterruptible:
    • A blocked state.
    • Process waits for a hardware condition and cannot handle any signal.
  • Stopped:
    • Process is stopped or halted and restarted by some other process.
  • Zombie:
    • Process terminated, but information is still there in the process table.

Developed by: