Operating System MCQs with Answers
Practice important Operating System MCQs with answers and explanations.
Multiple Choice Questions
Q271: What does the 'ps -u root' command display?
- A: Processes owned by the root user
- B: All processes running on the system
- C: Processes owned by the current user
- D: Processes in background
View Answer
A
Q272: In the client-server example, what does the server do after receiving a message from the client?
- A: It displays the message and sends a response
- B: It terminates the connection
- C: It creates new FIFO files
- D: It waits for another client
View Answer
B
Q273: Which system call is used to create a FIFO in UNIX/Linux?
- A: mknod
- B: mkfifo
- C: open
- D: pipe
View Answer
A
Q274: What is the purpose of the 'top' command in UNIX/Linux?
- A: Display CPU usage of processes
- B: Display list of files
- C: Display current directory
- D: List active users
View Answer
A
Q275: Which FIFO does the client write the message to?
- A: FIFO1
- B: FIFO2
- C: FIFO3
- D: FIFO4
View Answer
A
Q276: Which function is used to remove a FIFO in UNIX/Linux?
- A: unlink
- B: mknod
- C: rm
- D: open
View Answer
A
Q277: What is the file permission set for the FIFOs in the provided example?
- A: 644
- B: 666
- C: 777
- D: 600
View Answer
B
Q278: What is the purpose of the 'ps -e' command?
- A: Display all processes running on the system
- B: Display only processes of the current user
- C: Display processes in long format
- D: Display processes of root user
View Answer
A
Q279: What does the 'top' command show about the system?
- A: CPU usage, memory usage, and process information
- B: Only running processes
- C: Only CPU usage
- D: Memory usage of each user
View Answer
A
Q280: Which command displays the top processes based on CPU usage in real-time?
- A: ps
- B: top
- C: kill
- D: ls
View Answer
B