Courseiva

LPIC-1 Linux Installation and Package Management Practice Question

A user downloaded a Debian package file named 'software.deb'. Which command should be used to install it?

⚠ Common exam trap

Many exam-takers confuse `apt`/`apt-get` (which manage packages from repositories) with `dpkg` (which handles local `.deb` files), leading them to incorrectly assume `apt install` can accept a filename directly.

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

✓

dpkg -i software.deb

The correct command is `dpkg -i software.deb` because `dpkg` is the low-level package manager for Debian-based systems that directly installs `.deb` files. The `-i` flag tells `dpkg` to install the specified package file from the local filesystem, which is exactly what is needed when you have a downloaded `.deb` file.

Answer analysis

Option-by-option breakdown

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

  • ✗

    rpm -ivh software.deb

    Why it's wrong here

    rpm is for .rpm packages, not .deb.

  • ✗

    apt install software.deb

    Why it's wrong here

    apt install expects a package name resolved from repositories, not a local file path; it cannot install software.deb directly. apt is tempting because it handles dependencies, but for a downloaded .deb the correct tool is dpkg -i, optionally followed by apt install -f.

  • ✗

    apt-get install software.deb

    Why it's wrong here

    apt-get install resolves package names from configured repositories; it does not accept a local .deb filename as an argument, so the command errors. It is tempting because apt-get is the correct tool for installing Debian packages by name from a repository.

  • ✓

    dpkg -i software.deb

    Why this is correct

    dpkg -i installs a local .deb archive and runs its maintainer scripts, operating directly on the downloaded file. The stem specifies a local Debian package, so dpkg is the correct low-level installer rather than apt, which resolves repositories.

About these practice questions

This LPIC-1 question is part of Courseiva's 402-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.