cert
cert-1
cert-2

Pass CompTIA XK0-006 Exam in First Attempt Guaranteed!

Get 100% Latest Exam Questions, Accurate & Verified Answers to Pass the Actual Exam!
30 Days Free Updates, Instant Download!

cert-5
cert-6
XK0-006 Exam - Verified By Experts
XK0-006 Premium Bundle
$14.99

XK0-006 Premium Bundle

$74.99
$89.98
  • Premium File 160 Questions & Answers. Last update: Nov 15, 2026
  • Study Guide 1297 Pages
 
$89.98
$74.99
accept 32 downloads in last 7 days
block-screenshots
Purchase CompTIA XK0-006 Exam Training Products Individually
CompTIA XK0-006 Premium File
Premium File 160 Q&A
$76.99$69.99
CompTIA XK0-006 PDF Study Guide
Study Guide 1297 Pages
$21.99 $19.99
CompTIA XK0-006 Practice Test 33

Question 320

During an ordinary maintenance shift on a multi-user Linux service host, A developer loses existing supplementary groups after an admin runs usermod -G team to grant access to an additional team directory. The operator must identify the affected mechanism before approving changes to other services. What acceptance result would show the fix actually resolves the reported failure?

  1. A fresh test account receives the intended starter files without overwriting settings of existing accounts.
  2. id in the new session includes both the old supplemental groups and the newly granted group.
  3. systemctl status reports stable active state and the unit-scoped journal no longer shows repeated failure events.
  4. Approved remote requests succeed and unauthorized source probes remain blocked by the host firewall.

Explanation

Correct Answer

B:

id in the new session includes both the old supplemental groups and the newly granted group. This is direct acceptance evidence for supplementary group membership append rather than a generic process check. -G sets the supplementary-group list; -aG appends without removing existing groups. It validates the correction: Use usermod -aG newgroup username and arrange a new login session so the user's group list is refreshed. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A developer loses existing supplementary groups after an admin runs usermod -G team to grant access to an additional team directory. The operator must identify the affected mechanism before approving changes to other services.

Incorrect Answers

A:

A fresh test account receives the intended starter files without overwriting settings of existing accounts. This outcome would support default home-directory skeleton, but does not establish that the reported supplementary group membership append problem is resolved. The required direct acceptance test is: id in the new session includes both the old supplemental groups and the newly granted group. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A developer loses existing supplementary groups after an admin runs usermod -G team to grant access to an additional team directory. The operator must identify the affected mechanism before approving changes to other services.

C:

systemctl status reports stable active state and the unit-scoped journal no longer shows repeated failure events. This outcome would support systemd journal correlation, but does not establish that the reported supplementary group membership append problem is resolved. The required direct acceptance test is: id in the new session includes both the old supplemental groups and the newly granted group. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A developer loses existing supplementary groups after an admin runs usermod -G team to grant access to an additional team directory. The operator must identify the affected mechanism before approving changes to other services.

D:

Approved remote requests succeed and unauthorized source probes remain blocked by the host firewall. This outcome would support host firewall rejects container port, but does not establish that the reported supplementary group membership append problem is resolved. The required direct acceptance test is: id in the new session includes both the old supplemental groups and the newly granted group. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A developer loses existing supplementary groups after an admin runs usermod -G team to grant access to an additional team directory. The operator must identify the affected mechanism before approving changes to other services.

Question 321

During a production incident affecting a Linux application node, A microservice sometimes returns HTTP 503, but centralized logs lack host identity and timestamps are unsynchronized, so events cannot be correlated. The operator must identify the affected mechanism before approving changes to other services. Which diagnostic provides the most decisive FIRST evidence for the stated failure?

  1. Compare process presence with an end-to-end application health-check request, response code and representative latency.
  2. Compare log collector timestamps, host names, request correlation IDs and service metrics over the same incident window.
  3. Compare ip link show, path-MTU probes with the don't-fragment constraint, and the tunnel/overlay encapsulation overhead.
  4. Inspect per-thread CPU time, blocked-stack evidence and lock contention metrics before resizing the instance.

Explanation

Correct Answer

B:

Compare log collector timestamps, host names, request correlation IDs and service metrics over the same incident window. This checks the mechanism behind correlating service logs with host metrics. Time alignment and common identifiers enable diagnosis across distributed logs; raw unlabelled messages are hard to connect. Once identified, the targeted correction is: Normalize clocks and structured log labels, then aggregate service and host events with consistent identifiers. Confirm by checking: A known request failure can be traced across application, host and dependency logs by timestamp and correlation ID.

Incorrect Answers

A:

Compare process presence with an end-to-end application health-check request, response code and representative latency. This can investigate service health-check signal versus process running, but the given incident points to correlating service logs with host metrics. It is not the most decisive first evidence here. The discriminating test is: Compare log collector timestamps, host names, request correlation IDs and service metrics over the same incident window.

C:

Compare ip link show, path-MTU probes with the don't-fragment constraint, and the tunnel/overlay encapsulation overhead. This can investigate network interface mtu configuration, but the given incident points to correlating service logs with host metrics. It is not the most decisive first evidence here. The discriminating test is: Compare log collector timestamps, host names, request correlation IDs and service metrics over the same incident window. Scenario context: During a production incident affecting a Linux application node, A microservice sometimes returns HTTP 503, but centralized logs lack host identity and timestamps are unsynchronized, so events cannot be correlated. The operator must identify the affected mechanism before approving changes to other services.

D:

Inspect per-thread CPU time, blocked-stack evidence and lock contention metrics before resizing the instance. This can investigate thread contention versus raw cpu capacity, but the given incident points to correlating service logs with host metrics. It is not the most decisive first evidence here. The discriminating test is: Compare log collector timestamps, host names, request correlation IDs and service metrics over the same incident window.

Question 322

While preparing a recovery-site Linux node for a repeatable cutover, A nightly report incorrectly counts headers as records after a CSV-like log format change because grep only checks any digit in each line. The change must be repeatable and must not rely on broad permissions or bypassed safeguards. What acceptance result would show the fix actually resolves the reported failure?

  1. The service name resolves to the intended address and both name-based and IP-based connectivity work.
  2. The cron or systemd-scheduled invocation finds the intended executable without inheriting a user's interactive environment.
  3. Disk await and utilization normalize and application response times improve without adding CPU solely because load average was high.
  4. A known fixture yields the correct count for target records while excluding headers and unrelated numeric fields.

Explanation

Correct Answer

D:

A known fixture yields the correct count for target records while excluding headers and unrelated numeric fields. This is direct acceptance evidence for text filtering with grep and awk rather than a generic process check. Line-wide regular-expression matches do not enforce column semantics; field-aware filtering must use the actual delimiter. It validates the correction: Parse the intended column with an appropriate awk -F expression and exclude the header explicitly instead of matching a digit anywhere. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A nightly report incorrectly counts headers as records after a CSV-like log format change because grep only checks any digit in each line. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Incorrect Answers

A:

The service name resolves to the intended address and both name-based and IP-based connectivity work. This outcome would support name-resolution failure versus route failure, but does not establish that the reported text filtering with grep and awk problem is resolved. The required direct acceptance test is: A known fixture yields the correct count for target records while excluding headers and unrelated numeric fields. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A nightly report incorrectly counts headers as records after a CSV-like log format change because grep only checks any digit in each line. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

B:

The cron or systemd-scheduled invocation finds the intended executable without inheriting a user's interactive environment. This outcome would support path in noninteractive jobs, but does not establish that the reported text filtering with grep and awk problem is resolved. The required direct acceptance test is: A known fixture yields the correct count for target records while excluding headers and unrelated numeric fields. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A nightly report incorrectly counts headers as records after a CSV-like log format change because grep only checks any digit in each line. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

C:

Disk await and utilization normalize and application response times improve without adding CPU solely because load average was high. This outcome would support high i/o wait mistaken for cpu saturation, but does not establish that the reported text filtering with grep and awk problem is resolved. The required direct acceptance test is: A known fixture yields the correct count for target records while excluding headers and unrelated numeric fields. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A nightly report incorrectly counts headers as records after a CSV-like log format change because grep only checks any digit in each line. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Question 323

During a repeatability test on an independently built recovery environment, An infrastructure-as-code change would delete a production volume, but the team applies it without reviewing the planned resource changes or protecting state. The change must be repeatable and must not rely on broad permissions or bypassed safeguards. Which postchange observation most directly demonstrates successful remediation?

  1. The monitoring system has continuous trend samples and also receives test asynchronous fault notifications.
  2. The post-apply state matches approved resources with no unplanned deletions and the state lock is released correctly.
  3. The validated script changes only the intended test paths and does not affect system security-critical directories.
  4. New clones receive unique instance configuration without retaining another host's credentials in the base image.

Explanation

Correct Answer

B:

The post-apply state matches approved resources with no unplanned deletions and the state lock is released correctly. This is direct acceptance evidence for opentofu plan and state protection rather than a generic process check. IaC tools reconcile declared and recorded state; plan review and state protection prevent unintended destructive changes. It validates the correction: Review and approve the diff, protect remote state with locking/access control, and apply only the reviewed plan after unsafe deletes are corrected.

Incorrect Answers

A:

The monitoring system has continuous trend samples and also receives test asynchronous fault notifications. This outcome would support snmp polling versus traps, but does not establish that the reported opentofu plan and state protection problem is resolved. The required direct acceptance test is: The post-apply state matches approved resources with no unplanned deletions and the state lock is released correctly.

C:

The validated script changes only the intended test paths and does not affect system security-critical directories. This outcome would support ai-generated shell command validation, but does not establish that the reported opentofu plan and state protection problem is resolved. The required direct acceptance test is: The post-apply state matches approved resources with no unplanned deletions and the state lock is released correctly.

D:

New clones receive unique instance configuration without retaining another host's credentials in the base image. This outcome would support cloud-init initialization boundary, but does not establish that the reported opentofu plan and state protection problem is resolved. The required direct acceptance test is: The post-apply state matches approved resources with no unplanned deletions and the state lock is released correctly.

Question 324

While preparing a recovery-site Linux node for a repeatable cutover, A maintenance loop reads filenames containing spaces and deletes the wrong targets because variable expansions are unquoted. The change must be repeatable and must not rely on broad permissions or bypassed safeguards. Which diagnostic provides the most decisive FIRST evidence for the stated failure?

  1. Compare command -v, the interactive PATH, and the environment captured by the scheduled noninteractive shell.
  2. Inspect the script with shellcheck-style reasoning and demonstrate how for and test expressions split a filename containing spaces.
  3. Compare lsusb, lspci, and dmesg entries for the adapter's vendor/device ID and attachment bus.
  4. Check passwd -S, account shell and expiration fields before choosing the least disruptive lock procedure.

Explanation

Correct Answer

B:

Inspect the script with shellcheck-style reasoning and demonstrate how for and test expressions split a filename containing spaces. This checks the mechanism behind quoting filenames in shell loops. Unquoted shell expansions undergo word splitting and pathname expansion; safe iteration needs explicit quoting and delimiters. Once identified, the targeted correction is: Quote path expansions, use robust filename-safe iteration (such as find -print0 with null-delimited reading), and confirm deletion targets in dry-run mode. Confirm by checking: A test directory with spaces, tabs, and unusual characters is processed without splitting or unintended deletions. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A maintenance loop reads filenames containing spaces and deletes the wrong targets because variable expansions are unquoted. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Incorrect Answers

A:

Compare command -v, the interactive PATH, and the environment captured by the scheduled noninteractive shell. This can investigate path in noninteractive jobs, but the given incident points to quoting filenames in shell loops. It is not the most decisive first evidence here. The discriminating test is: Inspect the script with shellcheck-style reasoning and demonstrate how for and test expressions split a filename containing spaces. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A maintenance loop reads filenames containing spaces and deletes the wrong targets because variable expansions are unquoted. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

C:

Compare lsusb, lspci, and dmesg entries for the adapter's vendor/device ID and attachment bus. This can investigate detecting pci versus usb hardware, but the given incident points to quoting filenames in shell loops. It is not the most decisive first evidence here. The discriminating test is: Inspect the script with shellcheck-style reasoning and demonstrate how for and test expressions split a filename containing spaces. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A maintenance loop reads filenames containing spaces and deletes the wrong targets because variable expansions are unquoted. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

D:

Check passwd -S, account shell and expiration fields before choosing the least disruptive lock procedure. This can investigate local account lock versus password expiration, but the given incident points to quoting filenames in shell loops. It is not the most decisive first evidence here. The discriminating test is: Inspect the script with shellcheck-style reasoning and demonstrate how for and test expressions split a filename containing spaces. Scenario context: While preparing a recovery-site Linux node for a repeatable cutover, A maintenance loop reads filenames containing spaces and deletes the wrong targets because variable expansions are unquoted. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Question 325

During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services. Which TWO selections jointly provide the right evidence and corrective action? Select TWO.

  1. Bind the published admin port only to the approved loopback or management interface and enforce host firewall policy.
  2. Require named individual accounts with restricted sudo rules and preserve authorized sudo/audit logging for sensitive operations.
  3. Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing.
  4. Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access.
  5. Check passwd -S, account shell and expiration fields before choosing the least disruptive lock procedure.

Explanation

Correct Answers

C:

Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing. This supplies the decisive diagnostic observation for the stated fault. Rootless container UIDs and bind-mount labels must be compatible with host filesystem policy; mode 777 is not a safe generic fix. Pair this evidence with the targeted change: Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services.

D:

Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access. This is the targeted change needed after establishing the fault. Rootless container UIDs and bind-mount labels must be compatible with host filesystem policy; mode 777 is not a safe generic fix. Pair it with the supporting check: Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services.

Incorrect Answers

A:

Bind the published admin port only to the approved loopback or management interface and enforce host firewall policy. This choice concerns container port publishing scope rather than the required diagnosis-and-change pair for rootless podman bind mount access. Compare the needed evidence (Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing.) with the repair (Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access.). Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services.

B:

Require named individual accounts with restricted sudo rules and preserve authorized sudo/audit logging for sensitive operations. This choice concerns sudo action auditing rather than the required diagnosis-and-change pair for rootless podman bind mount access. Compare the needed evidence (Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing.) with the repair (Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access.). Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services.

E:

Check passwd -S, account shell and expiration fields before choosing the least disruptive lock procedure. This choice concerns local account lock versus password expiration rather than the required diagnosis-and-change pair for rootless podman bind mount access. Compare the needed evidence (Inspect podman inspect, host directory ownership, the rootless user namespace mapping and SELinux denial logs if enforcing.) with the repair (Align permitted host directory access with the container user namespace and supported SELinux relabeling options rather than granting world-writable access.). Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A rootless container starts but cannot write its bind-mounted host directory due to mapped UID/GID or security labeling mismatch. The operator must identify the affected mechanism before approving changes to other services.

Question 326

During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services. Which TWO choices form the decisive diagnosis AND targeted remediation? Select TWO.

  1. Inspect effective sshd -T settings, permitted authorized keys and authentication log entries for the exposed account.
  2. Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem.
  3. Issue and deploy a certificate whose SAN covers the intended DNS name from the approved trust chain, then reload the service.
  4. Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition.
  5. Correct the persistent file label or narrowly justified policy while keeping SELinux enforcing, instead of applying chmod 777.

Explanation

Correct Answers

B:

Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem. This is the targeted change needed after establishing the fault. LUKS adds a block encryption layer; the contained filesystem is accessed through the unlocked mapped device, not the encrypted raw bytes. Pair it with the supporting check: Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition. Scenario context: During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services.

D:

Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition. This supplies the decisive diagnostic observation for the stated fault. LUKS adds a block encryption layer; the contained filesystem is accessed through the unlocked mapped device, not the encrypted raw bytes. Pair this evidence with the targeted change: Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem. Scenario context: During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services.

Incorrect Answers

A:

Inspect effective sshd -T settings, permitted authorized keys and authentication log entries for the exposed account. This choice concerns ssh key authorization and root login rather than the required diagnosis-and-change pair for luks2 encrypted block-volume opening. Compare the needed evidence (Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition.) with the repair (Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem.). Scenario context: During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services.

C:

Issue and deploy a certificate whose SAN covers the intended DNS name from the approved trust chain, then reload the service. This choice concerns tls server certificate name mismatch rather than the required diagnosis-and-change pair for luks2 encrypted block-volume opening. Compare the needed evidence (Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition.) with the repair (Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem.). Scenario context: During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services.

E:

Correct the persistent file label or narrowly justified policy while keeping SELinux enforcing, instead of applying chmod 777. This choice concerns selinux avc denial versus unix mode rather than the required diagnosis-and-change pair for luks2 encrypted block-volume opening. Compare the needed evidence (Inspect lsblk -f, cryptsetup luksDump metadata and existing device-mapper mappings without attempting to format the raw LUKS partition.) with the repair (Open the existing LUKS2 device with cryptsetup open using authorized credentials, then mount its mapped filesystem.). Scenario context: During a compliance review of a production Linux endpoint, An encrypted secondary block device appears as random data to the filesystem tools because it has not been opened through its encrypted mapping. The operator must identify the affected mechanism before approving changes to other services.

Question 327

During a repeatability test on an independently built recovery environment, A Python helper uses subprocess.run with shell=True and concatenates a user-supplied filename into a command string. The change must be repeatable and must not rely on broad permissions or bypassed safeguards. Which outcome provides the strongest confirmation that the intended behavior is restored?

  1. df -i shows sufficient free inodes and representative small-file creation succeeds.
  2. The second playbook run reports no unnecessary package change and target hosts converge to the declared version/state.
  3. A crafted test filename is treated as data, not shell code, and failing processes raise a handled exception.
  4. Fresh clean installations resolve the approved package set and pass the same automated startup checks.

Explanation

Correct Answer

C:

A crafted test filename is treated as data, not shell code, and failing processes raise a handled exception. This is direct acceptance evidence for python subprocess invocation safety rather than a generic process check. Argument-list execution without a shell avoids shell metacharacter interpretation; blindly concatenating strings risks command injection. It validates the correction: Use a list of fixed executable arguments in subprocess.run(..., shell=False, check=True) and validate allowed file paths. Scenario context: During a repeatability test on an independently built recovery environment, A Python helper uses subprocess.run with shell=True and concatenates a user-supplied filename into a command string. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Incorrect Answers

A:

df -i shows sufficient free inodes and representative small-file creation succeeds. This outcome would support inode exhaustion on linux filesystem, but does not establish that the reported python subprocess invocation safety problem is resolved. The required direct acceptance test is: A crafted test filename is treated as data, not shell code, and failing processes raise a handled exception. Scenario context: During a repeatability test on an independently built recovery environment, A Python helper uses subprocess.run with shell=True and concatenates a user-supplied filename into a command string. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

B:

The second playbook run reports no unnecessary package change and target hosts converge to the declared version/state. This outcome would support ansible idempotent package management, but does not establish that the reported python subprocess invocation safety problem is resolved. The required direct acceptance test is: A crafted test filename is treated as data, not shell code, and failing processes raise a handled exception. Scenario context: During a repeatability test on an independently built recovery environment, A Python helper uses subprocess.run with shell=True and concatenates a user-supplied filename into a command string. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

D:

Fresh clean installations resolve the approved package set and pass the same automated startup checks. This outcome would support python dependency lock reproducibility, but does not establish that the reported python subprocess invocation safety problem is resolved. The required direct acceptance test is: A crafted test filename is treated as data, not shell code, and failing processes raise a handled exception. Scenario context: During a repeatability test on an independently built recovery environment, A Python helper uses subprocess.run with shell=True and concatenates a user-supplied filename into a command string. The change must be repeatable and must not rely on broad permissions or bypassed safeguards.

Question 328

During a planned automation rollout to a Linux fleet, A deployment stores an API credential in a plain ConfigMap committed to a public Git repository. The operator must identify the affected mechanism before approving changes to other services. What acceptance result would show the fix actually resolves the reported failure?

  1. A redeployed pod reads the rotated credential from the approved secret path and Git contains no active secret.
  2. New clones receive unique instance configuration without retaining another host's credentials in the base image.
  3. df -i shows sufficient free inodes and representative small-file creation succeeds.
  4. The merge commit retains both intended settings and tests pass without unresolved conflict markers.

Explanation

Correct Answer

A:

A redeployed pod reads the rotated credential from the approved secret path and Git contains no active secret. This is direct acceptance evidence for kubernetes configmap versus secret handling rather than a generic process check. A ConfigMap is for nonsensitive configuration; a Secret is a distinct Kubernetes object but still requires access and at-rest protection. It validates the correction: Remove the exposed credential, rotate it, and deliver sensitive settings via a controlled Kubernetes Secret/secret manager with suitable RBAC and encryption practices.

Incorrect Answers

B:

New clones receive unique instance configuration without retaining another host's credentials in the base image. This outcome would support cloud-init initialization boundary, but does not establish that the reported kubernetes configmap versus secret handling problem is resolved. The required direct acceptance test is: A redeployed pod reads the rotated credential from the approved secret path and Git contains no active secret.

C:

df -i shows sufficient free inodes and representative small-file creation succeeds. This outcome would support inode exhaustion on linux filesystem, but does not establish that the reported kubernetes configmap versus secret handling problem is resolved. The required direct acceptance test is: A redeployed pod reads the rotated credential from the approved secret path and Git contains no active secret. Scenario context: During a planned automation rollout to a Linux fleet, A deployment stores an API credential in a plain ConfigMap committed to a public Git repository. The operator must identify the affected mechanism before approving changes to other services.

D:

The merge commit retains both intended settings and tests pass without unresolved conflict markers. This outcome would support git conflict resolution without loss, but does not establish that the reported kubernetes configmap versus secret handling problem is resolved. The required direct acceptance test is: A redeployed pod reads the rotated credential from the approved secret path and Git contains no active secret.

Question 329

During an ordinary maintenance shift on a multi-user Linux service host, A systemd-managed API works after a manual launch but fails on every reboot because it was started but never enabled for the target boot mode. The operator must identify the affected mechanism before approving changes to other services. Which outcome provides the strongest confirmation that the intended behavior is restored?

  1. Interactive latency improves under load while the batch job continues with a less favorable nice value.
  2. The service is enabled, starts on the next controlled boot and remains healthy under systemd supervision.
  3. New clones receive unique instance configuration without retaining another host's credentials in the base image.
  4. list-timers shows an expected next trigger and a controlled firing records a successful service run.

Explanation

Correct Answer

B:

The service is enabled, starts on the next controlled boot and remains healthy under systemd supervision. This is direct acceptance evidence for systemd enable versus start rather than a generic process check. start activates a unit now; enable configures its installation links for automatic activation under the selected targets. It validates the correction: Enable the approved service for startup using systemctl enable (and start it now if needed), without editing the generated unit links manually. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A systemd-managed API works after a manual launch but fails on every reboot because it was started but never enabled for the target boot mode. The operator must identify the affected mechanism before approving changes to other services.

Incorrect Answers

A:

Interactive latency improves under load while the batch job continues with a less favorable nice value. This outcome would support process scheduling priority adjustment, but does not establish that the reported systemd enable versus start problem is resolved. The required direct acceptance test is: The service is enabled, starts on the next controlled boot and remains healthy under systemd supervision.

C:

New clones receive unique instance configuration without retaining another host's credentials in the base image. This outcome would support cloud-init initialization boundary, but does not establish that the reported systemd enable versus start problem is resolved. The required direct acceptance test is: The service is enabled, starts on the next controlled boot and remains healthy under systemd supervision.

D:

list-timers shows an expected next trigger and a controlled firing records a successful service run. This outcome would support systemd timer activation and calendar, but does not establish that the reported systemd enable versus start problem is resolved. The required direct acceptance test is: The service is enabled, starts on the next controlled boot and remains healthy under systemd supervision. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A systemd-managed API works after a manual launch but fails on every reboot because it was started but never enabled for the target boot mode. The operator must identify the affected mechanism before approving changes to other services.

Question 330

During an ordinary maintenance shift on a multi-user Linux service host, A Debian-family server unexpectedly selects a third-party build over the approved distribution version when two repositories publish the same package. The operator must identify the affected mechanism before approving changes to other services. What targeted corrective action best addresses the underlying problem?

  1. Repair the host's designated resolver or DNS search configuration and confirm the intended record is published.
  2. Configure precise APT package pinning for the approved origin and install the validated candidate without disabling unrelated security updates.
  3. Create a project virtual environment and install pinned project requirements into that isolated environment.
  4. Enable and start the timer unit, then confirm the associated service unit is referenced and the calendar expression is valid.

Explanation

Correct Answer

B:

Configure precise APT package pinning for the approved origin and install the validated candidate without disabling unrelated security updates. This action corrects apt package origin pinning without substituting an unrelated change. APT chooses candidates using versions and pin priorities; a repository being configured does not mean it is the only eligible source. Before acting, verify: Inspect apt-cache policy for candidate versions, priorities, repositories and installed version. Afterward confirm: apt-cache policy shows the intended priority/candidate and subsequent package operations keep the approved origin. Scenario context: During an ordinary maintenance shift on a multi-user Linux service host, A Debian-family server unexpectedly selects a third-party build over the approved distribution version when two repositories publish the same package. The operator must identify the affected mechanism before approving changes to other services.

Incorrect Answers

A:

Repair the host's designated resolver or DNS search configuration and confirm the intended record is published. This is a change associated with dns resolution versus tcp connectivity fault, not a targeted repair of apt package origin pinning. The described signal instead calls for: Configure precise APT package pinning for the approved origin and install the validated candidate without disabling unrelated security updates.

C:

Create a project virtual environment and install pinned project requirements into that isolated environment. This is a change associated with python application isolation from os packages, not a targeted repair of apt package origin pinning. The described signal instead calls for: Configure precise APT package pinning for the approved origin and install the validated candidate without disabling unrelated security updates.

D:

Enable and start the timer unit, then confirm the associated service unit is referenced and the calendar expression is valid. This is a change associated with systemd timer activation and calendar, not a targeted repair of apt package origin pinning. The described signal instead calls for: Configure precise APT package pinning for the approved origin and install the validated candidate without disabling unrelated security updates.

CompTIA Linux+ (XK0-006) Practice Tests