LPI Linux Essentials 010-160 Practice Exam Questions and Answers – Part 6/6

Practice for the LPI Linux Essentials exam with 12 exam-style practice questions, instant answer reveals, and concise explanations of every correct answer. Topics include: What column tells the "w" program which session is running?. Follow @CertPunch and visit certpunch.com for more certification practice exams and study content.

Prefer hands-on? Take this round as an interactive practice test — answer every question, get instant feedback, and see your score: Start the LPI Linux Essentials practice test →

What you will practice

  • What column tells the "w" program which session is running?
  • Which UID is usually used to represent the first regular user on a Linux system?
  • Which command would be used to change the owner of foo1.txt from jasondion to administrator?
  • Which of the following is NOT contained in the /etc/passwd file?
  • Which command is used to change the password of a user's account?
  • Which option can be used with useradd to specify the home directory for a user?

Answers and explanations

Tap a question to expand the answer and the exam reasoning. Try to commit to your own pick first.

Q1. What column tells the "w" program which session is running?

Answer: C. WHAT

The WHAT column in the w command output displays the specific process or program currently running in that user session. Do not confuse this with the USER or TTY columns, which only show login details.

Q2. Which UID is usually used to represent the first regular user on a Linux system?

Answer: D. 1000

Modern Linux distributions typically reserve identifiers starting from one thousand for regular user accounts. Lower numbers are designated for system processes and core services.

Q3. Which command would be used to change the owner of foo1.txt from jasondion to administrator?

Answer: D. chown

The chown command modifies file and directory ownership, requiring administrative privileges. Remember that chmod is used separately when you need to adjust file permissions rather than ownership.

Q4. Which of the following is NOT contained in the /etc/passwd file?

Answer: C. The password of the user's account

The passwd file contains account information but holds only a placeholder in the password field. Actual encrypted passwords are securely stored in the restricted shadow file instead.

Q5. Which command is used to change the password of a user's account?

Answer: C. passwd

The passwd utility updates a user authentication tokens and changes account passwords. Be careful not to confuse this command with pwd, which simply displays your current directory path.

Q6. Which option can be used with useradd to specify the home directory for a user?

Answer: A. -d

The dash d flag sets a specific home directory path when creating a new user account. In contrast, the dash c flag only adds descriptive comment fields like the user full name.

Q7. Where should temporary files be stored on a Linux system that can be safely deleted during a reboot?

Answer: C. /tmp

The root level temporary directory is explicitly designed to be cleared during system reboots. Conversely, temporary files kept in the var directory are preserved across system restarts.

Q8. Which of the following commands will output all of the lines with the name Fred in upper or lower case but not the word red from the file data_file?

Answer: A. grep '[Ff]red' data_file

Using bracket notation with uppercase and lowercase characters directly inside the search pattern catches both variations. Relying on basic flag searches without this notation misses the uppercase spelling.

Q9. Which of the following regular expressions matches lines beginning with the given pattern using the grep command?

Answer: A. ^pattern

The caret symbol anchors the search to the start of a line, ensuring it only matches text that begins with your pattern. The dollar sign anchors to the end of a line instead.

Q10. Which version of Linux should be installed on a system with a 32-bit processor?

Answer: C. x86

A system with a 32 bit processor requires an operating system compiled for the x86 architecture. The x64 architecture is strictly for 64 bit processors and cannot run on older 32 bit hardware.

Q11. Which of the following directories contains all of the installed kernels on your system and their needed drivers?

Answer: A. /boot

The boot directory contains the Linux kernel images and files needed during the startup process. The actual driver modules are stored separately under lib modules, making this option slightly imprecise.

Q12. Which file on a Linux system contains the passwords for each user on the system?

Answer: B. /etc/shadow

Encrypted user passwords are stored in the highly restricted shadow file. The passwd file contains basic account details but only holds a placeholder character where the password used to be.

More LPI Linux Essentials drills and other practice exams are on @CertPunch. New rounds drop every few days at certpunch.com.

Scroll to Top