Courseiva
TroubleshootinghardMultiple ChoiceObjective-mapped

XK0-006 Troubleshooting Practice Question

An administrator needs to capture network traffic on interface eth0, filter for packets to/from host 10.0.0.1, and save the output to a file for later analysis. Which command should be used?

⚠ Common exam trap

Test-takers frequently confuse `src` and `dst` filters as sufficient for capturing all traffic to/from a host, forgetting that `host` is the correct primitive for bidirectional capture.

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

tcpdump -i eth0 host 10.0.0.1 -w capture.pcap

The `tcpdump` command with the `host` filter captures all traffic (both source and destination) to or from the specified IP address, which matches the requirement to filter for packets to/from host 10.0.0.1. The `-i eth0` specifies the interface, and `-w capture.pcap` writes the output to a file for later analysis.

Answer analysis

Option-by-option breakdown

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

  • tcpdump -i eth0 src 10.0.0.1 -w capture.pcap

    Why it's wrong here

    This captures only source IP, not bidirectional.

  • tcpdump -i eth0 dst 10.0.0.1 -w capture.pcap

    Why it's wrong here

    This captures only destination IP, not bidirectional.

  • tcpdump -i eth0 host 10.0.0.1 -w capture.pcap

    Why this is correct

    Correct syntax: interface, host filter, and -w for output.

  • tcpdump -i eth0 -n host 10.0.0.1 -w capture.pcap

    Why it's wrong here

    -n disables name resolution but still works; however the question does not require -n.

Visual reference

Source Router + ACL permit 10.0.0.0/8 deny any Server 10.0.0.5 ✓ 192.168.1.1 ✗ dropped ACLs evaluate top-down; first match wins — implicit deny all at end

About these practice questions

One of 979 original XK0-006 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. 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.