Courseiva
hardMultiple Choice

XK0-006 Practice Question: During a security audit, a Linux administrator…

During a security audit, a Linux administrator finds that an unauthorized service is listening on TCP port 4444. The service is not managed by systemd. Which of the following commands should the administrator use to identify the process and disable it?

⚠ Common exam trap

Test-takers frequently assume all services are managed by systemd and reach for 'systemctl stop' or 'systemctl disable', but the question explicitly states the service is not managed by systemd, so only process-level commands like 'kill' are valid.

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

✓

Run 'ss -tlnp | grep :4444' to find the PID, then use 'kill' to terminate the process.

'ss -tlnp' lists TCP listening sockets with numeric addresses and the associated process PID. Piping the output through 'grep :4444' isolates the unauthorized service, and the PID can then be used with 'kill' to terminate the process. Since the service is not managed by systemd, systemctl commands are irrelevant, making 'kill' the appropriate method to stop the process.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✓

    Run 'ss -tlnp | grep :4444' to find the PID, then use 'kill' to terminate the process.

    Why this is correct

    ss -tlnp maps the listening socket on port 4444 to its owning PID, which is essential because the process is not managed by systemd and cannot be stopped via systemctl. Killing that PID then terminates the unauthorised listener, satisfying the audit's identification and disablement requirement.

  • ✗

    Run 'fuser 4444/tcp' to find the PID and then use 'systemctl stop' to stop the service.

    Why it's wrong here

    'fuser 4444/tcp' correctly returns the PID holding the port, but 'systemctl stop' only stops systemd units, and the stem states the service is not systemd-managed, so it cannot stop it. It is tempting because fuser is a valid port-to-process discovery tool and systemctl is the familiar service-control command.

  • ✗

    Run 'lsof -i :4444' to find the PID, then use 'systemctl disable' to disable the service.

    Why it's wrong here

    'lsof -i :4444' correctly identifies the PID, but 'systemctl disable' only affects systemd-managed units, and the stem states the service is not managed by systemd, so it cannot disable it. It is tempting because lsof is the right discovery tool and systemctl is the usual service-control method on modern distributions.

  • ✗

    Run 'systemctl status' to find the service name, then use 'systemctl stop' to stop it.

    Why it's wrong here

    'systemctl status' only queries systemd units, so it cannot identify a process that is not managed by systemd, and 'systemctl stop' likewise cannot stop it. It is tempting because systemctl is the standard service-management interface on systemd distributions, and would be correct for a systemd-managed unit.

About these practice questions

This XK0-006 question is part of Courseiva's 781-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This XK0-006 practice question is part of Courseiva's free CompTIA 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 XK0-006 exam.