






























































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!































































150+ Practice Questions with Answers & Rationales This comprehensive practice exam is designed to mirror the WGU D281 Linux Foundations Objective Assessment, covering topics aligned with the LPI Linux Essentials (010-160) certification. The exam is structured into key domains, with a focus on core Linux concepts, command-line utilities, system architecture, and open-source principles. SECTION 1: LINUX SYSTEM ARCHITECTURE Questions 1- 20 Q1. Which component of the Linux operating system directly manages hardware resources?
A) Shell B) Kernel C) Init system D) User space Correct Answer: B Rationale: The kernel is the core of Linux that interacts directly with hardware, managing memory, processes, and device drivers. It acts as the software glue between hardware and software. Q2. What is the first process started by the Linux kernel? A) init (PID 1) B) systemd (PID 1) C) Both A and B (depending on distribution) D) bash Correct Answer: C Rationale: PID 1 is the first user-space process started by the kernel. Traditional SysV systems use init, while modern systems use systemd. Both serve as the parent of all other processes.
Q5. Which directory is a virtual filesystem providing process and system information in real time? A) /proc B) /run C) /dev/shm D) /usr Correct Answer: A Rationale: /proc is a virtual filesystem (procfs) that contains runtime system information, including CPU, memory, and process data. It is created in memory at system boot. Q6. Which command displays CPU information? A) cat /proc/cpuinfo B) lscpu C) nproc D) All of the above Correct Answer: D
Rationale: cat /proc/cpuinfo displays detailed CPU information from the proc filesystem, lscpu formats it in a readable table, and nproc shows the number of processing cores. Q7. Which command displays memory information? A) free - h B) cat /proc/meminfo C) vmstat D) All of the above Correct Answer: D Rationale: free and vmstat display formatted memory information derived from /proc/meminfo. All three commands provide memory usage data in different formats. Q8. Which system call is used to create a new process in Linux? A) fork() B) exec()
A) modprobe module_name B) insmod /path/to/module.ko C) Both A and B D) modprobe - r Correct Answer: C Rationale: modprobe handles module dependencies automatically, while insmod loads a single module. modprobe - r is used to remove modules. Q11. Which command lists currently loaded kernel modules? A) lsmod B) cat /proc/modules C) Both A and B D) modinfo Correct Answer: C Rationale: lsmod formats /proc/modules into a readable table, making it easier to view loaded modules. modinfo provides information about a specific module.
Q12. Which signal cannot be caught or ignored by a process? A) SIGKILL (9) B) SIGSTOP (19) C) SIGTERM (15) D) Both A and B Correct Answer: D Rationale: SIGKILL and SIGSTOP cannot be caught, blocked, or ignored. SIGTERM can be caught and handled gracefully. Q13. Which command sends a SIGTERM to a process? A) kill PID B) kill - 15 PID C) kill - TERM PID D) All of the above Correct Answer: D Rationale: kill without a signal sends SIGTERM (15) by default. Both kill - 15 and kill - TERM explicitly send SIGTERM.
Q16. Which command shows the current default systemd target (runlevel)? A) systemctl get-default B) runlevel (legacy) C) who - r D) All of the above Correct Answer: D Rationale: systemctl get-default shows the default target, while runlevel and who - r show the current runlevel in legacy systems. Q17. Which command checks disk usage of mounted filesystems in human-readable format? A) df - h B) du - sh C) lsblk D) fdisk - l Correct Answer: A
Rationale: df (disk free) shows filesystem usage; - h makes it human-readable (e.g., 1G, 500M). du is used for directory-level disk usage. Q18. Which component of a Linux system is responsible for loading the kernel into memory? A) BIOS/UEFI and bootloader (GRUB) B) Init system C) Shell D) Kernel modules Correct Answer: A Rationale: The BIOS/UEFI initializes hardware, then loads the bootloader (GRUB), which loads the kernel into memory. Q19. What is the set of pages that explain every command available on the system? A) Man pages B) Help pages
Questions 21- 45 Q21. Which command displays the current working directory? A) cd B) pwd C) ls D) echo Correct Answer: B Rationale: pwd (print working directory) displays the absolute path of the current directory. Q22. Which command lists files and directories? A) cd B) pwd C) ls D) cp Correct Answer: C Rationale: ls displays the contents of a directory.
Q23. Which command changes directories? A) cd B) pwd C) ls D) mv Correct Answer: A Rationale: cd (change directory) is used to navigate between directories. Q24. Which command creates an empty file? A) touch B) mkdir C) cp D) rm Correct Answer: A Rationale: touch creates an empty file or updates the timestamp of an existing file.
C) mv D) touch Correct Answer: C Rationale: mv relocates files or changes their names. Q28. Which directory contains essential user commands? A) /tmp B) /home C) /bin D) /media Correct Answer: C Rationale: /bin stores essential executable commands needed for system operation. Q29. Which command displays the current user's username and user ID? A) whoami B) id
C) who D) Both A and B Correct Answer: D Rationale: whoami shows the current username, while id shows the username, user ID (UID), and group IDs. Q30. What is true about a recursive directory listing? A) It includes the content of sub-directories B) It includes the permissions of the directory listed C) It includes details of file system internals D) It includes ownership information for the files Correct Answer: A Rationale: A recursive directory listing (e.g., ls - R) includes the contents of subdirectories. Q31. Which command finds all lines in a file containing a term, regardless of case?
A) cat B) less C) head D) tail Correct Answer: C Rationale: head displays the first 10 lines of a file by default. Q34. Which command displays the last few lines of a file? A) cat B) less C) head D) tail Correct Answer: D Rationale: tail displays the last 10 lines of a file by default and is often used with - f to follow log files. Q35. Which command is used to search for a package in Debian/Ubuntu repositories?
A) rpm - qa B) yum search C) apt-cache search D) dnf find Correct Answer: C Rationale: apt-cache search allows you to query the Debian/Ubuntu package database. Q36. Which package management tool is used in Red Hat- based Linux systems? A) portage B) rpm C) dpkg D) apt Correct Answer: B Rationale: RPM (Red Hat Package Manager) is the low- level package manager in Red Hat-based distributions. Q37. Which command creates the ZIP archive poems.zip containing all .txt files?