LPIC-1 Linux Installation and Package Management Practice Question
Exhibit
deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main
Refer to the exhibit. An administrator is trying to install Google Chrome but receives a GPG error. Which command should be run to add the repository's GPG key?
⚠ Common exam trap
Many candidates confuse `gpg --import` (which affects the user's personal GPG keyring) with `apt-key add` (which affects the system-wide APT trusted keyring), or assume that any keyserver-based retrieval will work for all repositories.
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
✓
`wget -qO- https://dl.google.com/linux/linux_signing_key.pub | sudo apt-key add -`
It downloads the Google Linux signing key from the official URL and pipes it directly into `apt-key add`, which imports the key into APT's trusted keyring. This resolves the GPG error by allowing APT to verify the authenticity of packages from the Google Chrome repository.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
`wget -qO- https://dl.google.com/linux/linux_signing_key.pub | sudo apt-key add -`
Why this is correct
The pipeline downloads Google's signing key and pipes it into apt-key, adding the public key to APT's trusted keyring so the repository's Release signature verifies. This resolves the GPG error caused by the missing key for that repository.
- ✗
`gpg --import https://dl.google.com/linux/linux_signing_key.pub`
Why it's wrong here
gpg --import reads a local key file, not a URL, so it fails against an HTTPS path unless the key is first downloaded. It is tempting because importing a downloaded key is a valid manual step, but apt needs the key in its trusted keyring, which apt-key or a signed-by keyring file provides.
- ✗
`apt-key adv --keyserver keyserver.ubuntu.com --recv-keys <keyid>`
Why it's wrong here
This fetches a key from Ubuntu's keyserver, not Google's, so the retrieved key will not match the Google repository's signature and the GPG error persists. It is tempting because apt-key adv --recv-keys is the classic method, but only when the keyserver actually hosts the required key.
- ✗
`dpkg --add-key google`
Why it's wrong here
dpkg --add-key does not exist; dpkg has --add-architecture, not key management, so the command errors immediately. It is tempting because dpkg handles package installation and its database, but repository signing keys are managed by apt's keyring tooling, not dpkg itself.
Visual reference
Go deeper
Related to this question
About these practice questions
Courseiva writes every LPIC-1 question from scratch — 402 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
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.