LPI 010-160 Practice Test 80
Question 790
A backup job must preserve a directory tree in a .tar file. A check then reveals: Compression is not automatically enabled by every tar archive creation. Which targeted correction BEST restores the required behavior?
- Use `gzip project/` to collect an entire directory into one tar archive.
- Run `tar -xf project.tar project/` expecting to create a new archive.
- Use zip and unzip with the desired member paths.
- Specify creation and output file options with the source directory.
Explanation
Correct Answer
D:Specify creation and output file options with the source directory. This repairs Creating a tar archive and should be checked by seeing that the archive lists the intended files when inspected.
Incorrect Answers
A:Use `gzip project/` to collect an entire directory into one tar archive. This does not remedy the diagnosed Creating a tar archive failure; `tar -c` creates an archive and `-f` supplies its filename.
B:Run `tar -xf project.tar project/` expecting to create a new archive. This does not remedy the diagnosed Creating a tar archive failure; `tar -c` creates an archive and `-f` supplies its filename.
C:Use zip and unzip with the desired member paths. This is a remedy for ZIP archives and unzip, not the symptom in this Creating a tar archive case. Compression is not automatically enabled by every tar archive creation.
Question 791
A technician checks whether a NIC has an assigned IPv4 or IPv6 address. A check then reveals: Looking only at resolver configuration cannot reveal all assigned interface addresses. Which targeted correction BEST restores the required behavior?
- Run `ip route show` expecting all interface address records.
- Read only `/etc/hosts` to discover dynamic NIC assignments.
- Inspect interface addresses and link state before troubleshooting further.
- Use ping as a limited diagnostic alongside other network checks.
Explanation
Correct Answer
C:Inspect interface addresses and link state before troubleshooting further. This repairs ip addr show interface addresses and should be checked by seeing that the output lists addresses assigned to the specified network interface.
Incorrect Answers
A:Run `ip route show` expecting all interface address records. This does not remedy the diagnosed ip addr show interface addresses failure; iP address assignment and interface status are independent of DNS hostname resolution.
B:Read only `/etc/hosts` to discover dynamic NIC assignments. This does not remedy the diagnosed ip addr show interface addresses failure; iP address assignment and interface status are independent of DNS hostname resolution.
D:Use ping as a limited diagnostic alongside other network checks. This is a remedy for ping reachability testing, not the symptom in this ip addr show interface addresses case. Looking only at resolver configuration cannot reveal all assigned interface addresses.
Question 792
A user moves a file from `~/Downloads` into a project directory. A check then reveals: Using `cp` leaves the original behind when a move was required. Which targeted correction BEST restores the required behavior?
- Use `cp` and assume the original automatically disappears.
- Use `touch` on the requested file path.
- Run `touch` to rename an existing file.
- Move the item after checking whether a destination exists.
Explanation
Correct Answer
D:Move the item after checking whether a destination exists. This repairs mv rename and relocation and should be checked by seeing that the destination path exists and the original name no longer refers to the same entry.
Incorrect Answers
A:Use `cp` and assume the original automatically disappears. This does not remedy the diagnosed mv rename and relocation failure; `mv` renames or relocates filesystem objects rather than duplicating them.
B:Use `touch` on the requested file path. This is a remedy for touch empty files and timestamps, not the symptom in this mv rename and relocation case. Using `cp` leaves the original behind when a move was required.
C:Run `touch` to rename an existing file. This does not remedy the diagnosed mv rename and relocation failure; `mv` renames or relocates filesystem objects rather than duplicating them.
Question 793
A researcher needs to archive and compress nested files in one tar invocation. A check then reveals: Missing compression leaves an uncompressed tar despite a .gz-looking filename. Which targeted correction BEST restores the required behavior?
- Use `tar -xzf project.tar.gz project/` as the creation command.
- Change only the filename suffix to enable gzip.
- Inspect the archive and extract into an intended destination.
- Create with the appropriate tar compression flag and verify extraction.
Explanation
Correct Answer
D:Create with the appropriate tar compression flag and verify extraction. This repairs tar gzip combined compression and should be checked by seeing that the resulting archive extracts with `tar -xzf` and contains the original hierarchy.
Incorrect Answers
A:Use `tar -xzf project.tar.gz project/` as the creation command. This does not remedy the diagnosed tar gzip combined compression failure; the tar `-z` option requests gzip compression while `-c` creates the archive.
B:Change only the filename suffix to enable gzip. This does not remedy the diagnosed tar gzip combined compression failure; the tar `-z` option requests gzip compression while `-c` creates the archive.
C:Inspect the archive and extract into an intended destination. This is a remedy for Extracting a tar archive, not the symptom in this tar gzip combined compression case. Missing compression leaves an uncompressed tar despite a .gz-looking filename.
Question 794
An administrator examines a distribution's boot files for the installed kernel. A check then reveals: Mistaking runtime logs for boot images can cause administration errors. Which targeted correction BEST restores the required behavior?
- Identify boot files using the distribution's boot layout.
- Search `/tmp` as the universal permanent kernel image location.
- Use documented sysfs interfaces for inspecting hardware state.
- Use `/etc/passwd` as the Linux bootloader binary.
Explanation
Correct Answer
A:Identify boot files using the distribution's boot layout. This repairs /boot kernel startup files and should be checked by seeing that kernel images or loader assets appear in the designated boot path.
Incorrect Answers
B:Search `/tmp` as the universal permanent kernel image location. This does not remedy the diagnosed /boot kernel startup files failure; `/boot` commonly stores files needed during the system boot process.
C:Use documented sysfs interfaces for inspecting hardware state. This is a remedy for /sys device and kernel interfaces, not the symptom in this /boot kernel startup files case. Mistaking runtime logs for boot images can cause administration errors.
D:Use `/etc/passwd` as the Linux bootloader binary. This does not remedy the diagnosed /boot kernel startup files failure; `/boot` commonly stores files needed during the system boot process.
Question 795
A student wants to view the structured Info manual for a supported GNU utility. A check then reveals: Treating Info as a command-execution shell does not reveal documentation. Which targeted correction BEST restores the required behavior?
- Launch an Info reader for the relevant GNU documentation.
- Expect `rmdir` to display an Info manual.
- Consult help output or the documented manual.
- Use `chmod` to navigate Info nodes.
Explanation
Correct Answer
A:Launch an Info reader for the relevant GNU documentation. This repairs Info documentation navigation and should be checked by seeing that a navigable set of linked Info nodes is available.
Incorrect Answers
B:Expect `rmdir` to display an Info manual. This does not remedy the diagnosed Info documentation navigation failure; gNU Info documents are organized as hypertext-style nodes, distinct from plain file listings.
C:Consult help output or the documented manual. This is a remedy for Command --help output, not the symptom in this Info documentation navigation case. Treating Info as a command-execution shell does not reveal documentation.
D:Use `chmod` to navigate Info nodes. This does not remedy the diagnosed Info documentation navigation failure; gNU Info documents are organized as hypertext-style nodes, distinct from plain file listings.
Question 796
A text analyst needs to find matching terms regardless of capitalization. A check then reveals: A case-sensitive search can miss variants of a keyword. Which targeted correction BEST restores the required behavior?
- Use `sort -r` as grep's case-insensitive option.
- Run `grep -v warning` expecting to ignore case.
- Apply case-insensitive matching when letter case is not meaningful.
- Select a grep pattern that matches the target term.
Explanation
Correct Answer
C:Apply case-insensitive matching when letter case is not meaningful. This repairs grep -i ignore case and should be checked by seeing that lines with the term in different letter cases are selected.
Incorrect Answers
A:Use `sort -r` as grep's case-insensitive option. This does not remedy the diagnosed grep -i ignore case failure; the `-i` option makes grep ignore case distinctions in matching.
B:Run `grep -v warning` expecting to ignore case. This does not remedy the diagnosed grep -i ignore case failure; the `-i` option makes grep ignore case distinctions in matching.
D:Select a grep pattern that matches the target term. This is a remedy for grep fixed text matching, not the symptom in this grep -i ignore case case. A case-sensitive search can miss variants of a keyword.
Question 797
A technician estimates power needs for storage and additional graphics hardware. A check then reveals: Underpowered hardware can cause instability despite healthy software. Which targeted correction BEST restores the required behavior?
- Check power budget and physical connector compatibility.
- Treat a network router as the system's PSU.
- Measure the relevant hardware resource before upgrading.
- Increase Linux swap as the sole electrical power fix.
Explanation
Correct Answer
A:Check power budget and physical connector compatibility. This repairs Power supply for components and should be checked by seeing that the machine remains stable under the expected electrical load.
Incorrect Answers
B:Treat a network router as the system's PSU. This does not remedy the diagnosed Power supply for components failure; the PSU converts and distributes power to system components and must meet load needs.
C:Measure the relevant hardware resource before upgrading. This is a remedy for CPU and RAM responsibilities, not the symptom in this Power supply for components case. Underpowered hardware can cause instability despite healthy software.
D:Increase Linux swap as the sole electrical power fix. This does not remedy the diagnosed Power supply for components failure; the PSU converts and distributes power to system components and must meet load needs.
Question 798
A student needs to match either one of two literal characters in the middle of a word. A check then reveals: Literal unquoted brackets or the wrong pattern can change the match set. Which targeted correction BEST restores the required behavior?
- Use `grep 'c(ao)t'` as a basic-regex guarantee of either character.
- Treat `*` as a shell filename wildcard inside every regular expression.
- Build a bracket class for the allowed characters.
- Select overwrite or append intentionally and verify file contents.
Explanation
Correct Answer
C:Build a bracket class for the allowed characters. This repairs Basic regular-expression character classes and should be checked by seeing that lines containing either indicated single-character alternative match.
Incorrect Answers
A:Use `grep 'c(ao)t'` as a basic-regex guarantee of either character. This does not remedy the diagnosed Basic regular-expression character classes failure; a regex bracket expression denotes a one-character class rather than an entire word choice.
B:Treat `*` as a shell filename wildcard inside every regular expression. This does not remedy the diagnosed Basic regular-expression character classes failure; a regex bracket expression denotes a one-character class rather than an entire word choice.
D:Select overwrite or append intentionally and verify file contents. This is a remedy for Redirecting output and append, not the symptom in this Basic regular-expression character classes case. Literal unquoted brackets or the wrong pattern can change the match set.
Question 799
A trainee needs to repeat one harmless operation over matching pathnames. A check then reveals: Using a quoted literal glob as the loop source prevents normal pathname expansion. Which targeted correction BEST restores the required behavior?
- Switch modes intentionally and save with a write command.
- Run `rm *.log` instead of iterating when processing is required.
- Iterate over a glob and quote the loop variable when passed to commands.
- Write `for file in '*.log'` expecting shell expansion of the quoted pattern.
Explanation
Correct Answer
C:Iterate over a glob and quote the loop variable when passed to commands. This repairs Loop over matching filenames and should be checked by seeing that each matched filename is processed as its own argument.
Incorrect Answers
A:Switch modes intentionally and save with a write command. This is a remedy for vi insert mode and write quit, not the symptom in this Loop over matching filenames case. Using a quoted literal glob as the loop source prevents normal pathname expansion.
B:Run `rm *.log` instead of iterating when processing is required. This does not remedy the diagnosed Loop over matching filenames failure; a pathname glob can supply the loop's items while quoted variable expansion preserves each filename.
D:Write `for file in '*.log'` expecting shell expansion of the quoted pattern. This does not remedy the diagnosed Loop over matching filenames failure; a pathname glob can supply the loop's items while quoted variable expansion preserves each filename.
Question 800
A trainee wants to list local listening TCP sockets on Linux. A check then reveals: Checking only IP assignment does not prove an application is listening. Which targeted correction BEST restores the required behavior?
- Run `route` to list process socket states.
- Inspect sockets with ss and then verify network filtering.
- Use `ip addr show` expecting all listening TCP port details.
- Test DNS answers separately from ping or routing.
Explanation
Correct Answer
B:Inspect sockets with ss and then verify network filtering. This repairs ss listening sockets and should be checked by seeing that the service's TCP listening socket appears with the intended local address.
Incorrect Answers
A:Run `route` to list process socket states. This does not remedy the diagnosed ss listening sockets failure; a listening socket is necessary for incoming TCP service connections but firewall routing may also matter.
C:Use `ip addr show` expecting all listening TCP port details. This does not remedy the diagnosed ss listening sockets failure; a listening socket is necessary for incoming TCP service connections but firewall routing may also matter.
D:Test DNS answers separately from ping or routing. This is a remedy for host DNS name lookup, not the symptom in this ss listening sockets case. Checking only IP assignment does not prove an application is listening.