LPI 102-500 Practice Test 51
Question 500
A helpdesk escalation describes this Linux behavior: A machine joins an open guest network when an approved WPA2-enterprise connection should be preferred after restart. Which THREE elements together give the appropriate corrective action, direct diagnostic evidence and observable acceptance result? Select THREE answers.
- Inspect available SSIDs, connection authentication settings, device state, connection activation logs and effective routes.
- Inspect `ip -br link`, `ip address show`, carrier state and manager logs before and after a controlled interface activation.
- The device associates to the approved wireless network, authenticates successfully and receives the expected network configuration.
- Assume a displayed Wi-Fi SSID guarantees valid credentials and that any automatically connected access point is the approved enterprise network.
- Map required common services to their correct transport and port, including SSH 22/TCP, HTTP 80/TCP, HTTPS 443/TCP and DNS 53/UDP or TCP where used.
- Inspect and configure the appropriate `nmcli device wifi` and connection profile settings with approved authentication, secrets and autoconnect preferences.
Explanation
Correct Answers
A:Most direct verification evidence: Inspect available SSIDs, connection authentication settings, device state, connection activation logs and effective routes. Linux principle: Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
C:Observable acceptance criterion: The device associates to the approved wireless network, authenticates successfully and receives the expected network configuration. Linux principle: Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
F:Recommended administrative action: Inspect and configure the appropriate `nmcli device wifi` and connection profile settings with approved authentication, secrets and autoconnect preferences. Linux principle: Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
Incorrect Answers
B:That option would inspect `ip -br link`, `ip address show`, carrier state and manager logs before and after a controlled interface activation, but it addresses a different concern. Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
D:This shortcut is unsafe for the present Linux issue: Assume a displayed Wi-Fi SSID guarantees valid credentials and that any automatically connected access point is the approved enterprise network. Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
E:That option would map required common services to their correct transport and port, including SSH 22/TCP, HTTP 80/TCP, HTTPS 443/TCP and DNS 53/UDP or TCP where used, but it addresses a different concern. Wireless association, authentication and IP configuration are distinct stages; an SSID's visibility does not establish authorized connectivity.
Question 501
An operations handoff identifies this problem: A provisioning script runs `hostname tempname` and the system returns to its original name after a restart. Which administrative step is the MOST appropriate way to resolve this issue? Select ONE best answer.
- Inspect `ip route` and selected `ip route get`, then set or repair the appropriate default route in the active manager or with `ip route` for a controlled temporary change.
- Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
- Use `nmcli connection` to edit the correct NetworkManager profile's IPv4 method, addresses, gateway and activation settings, then reapply deliberately.
Explanation
Correct Answer
B:Recommended administrative action: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately.
Incorrect Answers
A:This alternative addresses Linux routing tables and default gateway selection, not the specific issue of Hostnamectl and durable host identification: Inspect `ip route` and selected `ip route get`, then set or repair the appropriate default route in the active manager or with `ip route` for a controlled temporary change. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
C:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
D:That option would use `nmcli connection` to edit the correct NetworkManager profile's IPv4 method, addresses, gateway and activation settings, then reapply deliberately, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Question 502
A team maintaining a Linux host reports: A provisioning script runs `hostname tempname` and the system returns to its original name after a restart. Which Linux behavior or technical principle BEST explains why the issue occurs? Select ONE best answer.
- A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
- RFC1918 private IPv4 ranges are 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16; not every 172.x or 192.x address is private.
- Different Linux networking managers apply persistent interface settings through their own configurations; conflicting ownership can cause changes to be ignored or overwritten.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
Explanation
Correct Answer
A:Relevant Linux operating principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
B:This alternative addresses RFC1918 private addressing and internet routing, not the specific issue of Hostnamectl and durable host identification: RFC1918 private IPv4 ranges are 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16; not every 172.x or 192.x address is private. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
C:This alternative addresses NetworkManager and systemd-networkd configuration ownership, not the specific issue of Hostnamectl and durable host identification: Different Linux networking managers apply persistent interface settings through their own configurations; conflicting ownership can cause changes to be ignored or overwritten. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
D:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Question 503
While verifying a Linux change request, an engineer finds: A provisioning script runs `hostname tempname` and the system returns to its original name after a restart. Which evidence or command result MOST directly tests the suspected root cause? Select ONE best answer.
- Inspect `ss -ltnp`, service bind configuration, local and remote connection attempts and firewall rules.
- Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
- Compare `getent hosts name`, /etc/nsswitch.conf hosts line, /etc/hosts entry and DNS-only `dig` output.
Explanation
Correct Answer
B:Most direct verification evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot.
Incorrect Answers
A:This alternative addresses Listening sockets with ss and netcat testing, not the specific issue of Hostnamectl and durable host identification: Inspect `ss -ltnp`, service bind configuration, local and remote connection attempts and firewall rules.
C:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. It cannot establish a safe correction. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
D:This alternative addresses Local hosts resolution versus DNS settings, not the specific issue of Hostnamectl and durable host identification: Compare `getent hosts name`, /etc/nsswitch.conf hosts line, /etc/hosts entry and DNS-only `dig` output.
Question 504
A Linux administrator investigates the following system incident: A provisioning script runs `hostname tempname` and the system returns to its original name after a restart. Which observed outcome BEST confirms a successful and properly scoped correction? Select ONE best answer.
- The service listens on the authorized address and port and approved remote clients can connect while unauthorized origins remain blocked.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
- Only the chosen manager owns the interface and configuration survives a controlled network-service restart without unexpected overrides.
- The host reports the approved name consistently and local resolution returns the correct intended addresses.
Explanation
Correct Answer
D:Observable acceptance criterion: The host reports the approved name consistently and local resolution returns the correct intended addresses.
Incorrect Answers
A:This alternative addresses Listening sockets with ss and netcat testing, not the specific issue of Hostnamectl and durable host identification: The service listens on the authorized address and port and approved remote clients can connect while unauthorized origins remain blocked. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
B:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. It cannot establish a safe correction. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
C:This alternative addresses NetworkManager and systemd-networkd configuration ownership, not the specific issue of Hostnamectl and durable host identification: Only the chosen manager owns the interface and configuration survives a controlled network-service restart without unexpected overrides. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
Question 505
On a production Linux workstation or server, a technician observes: A provisioning script runs `hostname tempname` and the system returns to its original name after a restart. Which misleading assumption MOST directly contributes to this failure and should be rejected? Select ONE best answer.
- Use only a transient `ip addr add` command and expect NetworkManager to persist it automatically after every reboot.
- Assume having any IPv4 address automatically creates a correct default gateway and that multiple default routes always provide harmless equal-cost failover.
- Assume any file under /etc/systemd/network will control an interface regardless of which network manager actually owns the device.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
Explanation
Correct Answer
D:Reject this specific misconception: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. It incorrectly assumes behavior that conflicts with the observed Linux conditions.
Incorrect Answers
A:That option would use only a transient `ip addr add` command and expect NetworkManager to persist it automatically after every reboot, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
B:That option would assume having any IPv4 address automatically creates a correct default gateway and that multiple default routes always provide harmless equal-cost failover, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
C:That option would assume any file under /etc/systemd/network will control an interface regardless of which network manager actually owns the device, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Question 506
During an LPIC-1 practice lab, the operator encounters this condition: A workstation has conflicting static hostname and /etc/hosts entries, causing local name lookups to refer to the wrong node. Which administrative step is the MOST appropriate way to resolve this issue? Select ONE best answer.
- Inspect and configure the appropriate `nmcli device wifi` and connection profile settings with approved authentication, secrets and autoconnect preferences.
- Calculate network and host ranges from the prefix length and configure correct address, subnet prefix and route or gateway for remote destinations.
- Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
Explanation
Correct Answer
C:Recommended administrative action: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
A:That option would inspect and configure the appropriate `nmcli device wifi` and connection profile settings with approved authentication, secrets and autoconnect preferences, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
B:This alternative addresses IPv4 CIDR network masks and subnet reachability, not the specific issue of Hostnamectl and durable host identification: Calculate network and host ranges from the prefix length and configure correct address, subnet prefix and route or gateway for remote destinations. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
D:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Question 507
A helpdesk escalation describes this Linux behavior: A workstation has conflicting static hostname and /etc/hosts entries, causing local name lookups to refer to the wrong node. Which Linux behavior or technical principle BEST explains why the issue occurs? Select ONE best answer.
- IPv6 commonly uses 128-bit addresses and prefix notation; fe80::/10 link-local addresses are limited to one link and typically need an interface zone for selection.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
- A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
- The iproute2 command changes and reports kernel interface state, while durable settings are managed by the host's networking service.
Explanation
Correct Answer
C:Relevant Linux operating principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
A:This alternative addresses IPv6 addressing link-local scope and prefix rules, not the specific issue of Hostnamectl and durable host identification: IPv6 commonly uses 128-bit addresses and prefix notation; fe80::/10 link-local addresses are limited to one link and typically need an interface zone for selection. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
B:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. It cannot establish a safe correction. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
D:This alternative addresses Ip command address and link troubleshooting, not the specific issue of Hostnamectl and durable host identification: The iproute2 command changes and reports kernel interface state, while durable settings are managed by the host's networking service. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
Question 508
An operations handoff identifies this problem: A workstation has conflicting static hostname and /etc/hosts entries, causing local name lookups to refer to the wrong node. Which evidence or command result MOST directly tests the suspected root cause? Select ONE best answer.
- Consult /etc/services, inspect listening sockets with `ss` and test service behavior against firewall or resolver rules.
- Inspect available SSIDs, connection authentication settings, device state, connection activation logs and effective routes.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
- Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot.
Explanation
Correct Answer
D:Most direct verification evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
A:This alternative addresses Well-known TCP UDP port mapping, not the specific issue of Hostnamectl and durable host identification: Consult /etc/services, inspect listening sockets with `ss` and test service behavior against firewall or resolver rules.
B:This alternative addresses NetworkManager Wi-Fi authentication and saved profiles, not the specific issue of Hostnamectl and durable host identification: Inspect available SSIDs, connection authentication settings, device state, connection activation logs and effective routes.
C:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. It cannot establish a safe correction. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
Question 509
A team maintaining a Linux host reports: A workstation has conflicting static hostname and /etc/hosts entries, causing local name lookups to refer to the wrong node. Which observed outcome BEST confirms a successful and properly scoped correction? Select ONE best answer.
- The host reports the approved name consistently and local resolution returns the correct intended addresses.
- The service listens on the authorized address and port and approved remote clients can connect while unauthorized origins remain blocked.
- Hosts are classified as private or globally addressed correctly and required outbound communication uses approved routing or NAT.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
Explanation
Correct Answer
A:Observable acceptance criterion: The host reports the approved name consistently and local resolution returns the correct intended addresses. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
B:This alternative addresses Listening sockets with ss and netcat testing, not the specific issue of Hostnamectl and durable host identification: The service listens on the authorized address and port and approved remote clients can connect while unauthorized origins remain blocked. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
C:This alternative addresses RFC1918 private addressing and internet routing, not the specific issue of Hostnamectl and durable host identification: Hosts are classified as private or globally addressed correctly and required outbound communication uses approved routing or NAT. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions. Appropriate response: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Root-cause evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Independent acceptance: The host reports the approved name consistently and local resolution returns the correct intended addresses.
D:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Question 510
While verifying a Linux change request, an engineer finds: A workstation has conflicting static hostname and /etc/hosts entries, causing local name lookups to refer to the wrong node. Which TWO complementary steps provide the best corrective action and its most direct diagnostic verification? Select TWO answers.
- Inspect `systemctl` service state, NetworkManager device management, /etc/systemd/network and active connection profiles alongside `ip` state.
- Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately.
- Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot.
- Use `ip link` and `ip addr` to examine and adjust temporary interface state and repair the persistent manager configuration where required.
- Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically.
Explanation
Correct Answers
B:Recommended administrative action: Set the intended persistent static hostname with `hostnamectl` or supported distribution settings and validate local host mapping separately. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
C:Most direct verification evidence: Inspect `hostnamectl status`, /etc/hostname, /etc/hosts and `getent hosts` output before and after reboot. Linux principle: A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
Incorrect Answers
A:This alternative addresses NetworkManager and systemd-networkd configuration ownership, not the specific issue of Hostnamectl and durable host identification: Inspect `systemctl` service state, NetworkManager device management, /etc/systemd/network and active connection profiles alongside `ip` state.
D:That option would use `ip link` and `ip addr` to examine and adjust temporary interface state and repair the persistent manager configuration where required, but it addresses a different concern. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.
E:This shortcut is unsafe for the present Linux issue: Assume the command `hostname newname` persistently changes every host identification file and DNS record automatically. A transient hostname change is not necessarily persisted; hostname resolution and the configured system hostname are related but distinct functions.