220-1102 exam dumps

220-1102 practice question 250 of 828

A+ Core 2. Associate level, CompTIA. Free question with the correct answer and a full explanation.

220-1102 Question 250

Single answerPackage management

A Linux workstation in a small office cannot install a required graphics package from the command line. When the technician runs the install command, the package manager reports that the package information is outdated and the package cannot be located. Internet access is working, and the repository configuration has not changed. Which action should the technician take FIRST to resolve the issue?

  1. A

    Refresh the local package index from the configured repositories, then try the installation again

  2. B

    Force-install the package manually with a low-level package tool to bypass repository checks

  3. C

    Reboot the workstation so the package manager can rebuild its package database automatically

  4. D

    Remove all currently installed graphics-related packages before attempting the new installation

Show answer and explanation

Correct answer: A

Explanation

The best first action is to refresh the package manager's local metadata cache from the configured repositories. In real-world Linux administration, package managers use repository indexes to determine what packages are available and which versions can be installed. If those indexes are stale, commands to install a package may fail with messages indicating the package cannot be located. Best practice is to update the repository metadata first, then perform the installation. This aligns with common Linux package-management workflows documented for APT-based systems and RPM-based systems, where refreshing repository information is a standard step before installing software.

  • A. Correct.

    Correct. In Linux package management, the package manager relies on locally cached metadata about available packages in configured repositories. If that metadata is outdated, the system may report that a package cannot be found even though it exists in the repository. The first step is to refresh or update the package index, such as with commands like apt update or dnf check-update/makecache depending on the distribution, and then retry the install.

  • B. Incorrect.

    Incorrect. Low-level tools such as dpkg or rpm install local package files directly and do not resolve repository metadata issues or dependencies in the same way as higher-level package managers. Bypassing repository checks can make the situation worse, especially if dependencies are missing or package versions are incompatible.

  • C. Incorrect.

    Incorrect. Rebooting is not a standard first troubleshooting step for package metadata problems. Package managers do not typically require a reboot to refresh repository listings. A reboot might be chosen by someone applying generic troubleshooting habits, but it does not address outdated package indexes.

  • D. Incorrect.

    Incorrect. Removing related packages is unnecessary and risky. The problem described is that the package manager cannot locate the package due to outdated package information, not that there is a package conflict. Uninstalling graphics packages could disrupt the user's system without resolving the underlying repository metadata issue.

Timed practice exam

Take a 220-1102 practice test under exam conditions

90 questions in 90 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam