Courseiva
Linux Installation and Package ManagementmediumMultiple ChoiceObjective-mapped

LPIC-1 Linux Installation and Package Management Practice Question

A system administrator needs to install a package 'foo' which depends on library 'libbar.so.2' that is not currently installed. The administrator runs `apt-get install foo` and receives an error about unmet dependencies. Which of the following is the most appropriate next step?

⚠ Common exam trap

It's easy for candidates to confuse `apt-get update` (which only refreshes package lists) with `apt-get install -f` (which actually repairs broken dependencies), leading them to choose option C as a first troubleshooting step when the real issue is a missing dependency, not an outdated index.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Run `apt-get install -f` to fix broken dependencies.

`apt-get install -f` (or `apt --fix-broken install`) attempts to correct a system with broken dependencies by installing missing packages or removing conflicting ones. In this scenario, the unmet dependency is `libbar.so.2`, and running this command will automatically resolve the dependency chain by installing the required library package, assuming it is available in the configured repositories.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Run `apt-get install -f` to fix broken dependencies.

    Why this is correct

    This command attempts to correct unmet dependencies.

  • Use `dpkg --force-depends -i foo.deb` to force installation.

    Why it's wrong here

    Forcing installation can leave the system with broken packages.

  • Run `apt-get update` and retry the installation.

    Why it's wrong here

    Updating the package list does not fix dependency issues.

  • Manually download `libbar.so.2` and install it using `dpkg -i`.

    Why it's wrong here

    Manual installation may not resolve all dependencies and is not recommended.

Visual reference

Client Recursive Resolver Root DNS (13 root servers) TLD DNS (.com, .org, …) Authoritative example.com query IP addr answer

About these practice questions

This LPIC-1 question is part of Courseiva's 527-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This LPIC-1 practice question is part of Courseiva's free LPI certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LPIC-1 exam.