Courseiva
NetworkinghardMultiple ChoiceObjective-mapped

LFCS Networking Practice Question

Which nmcli command creates a VLAN interface with tag 10 on device eth0?

⚠ Common exam trap

Many exam-takers confuse `ifname` (which sets the resulting interface name) with `dev` (which specifies the parent device), leading candidates to incorrectly use `ifname eth0` instead of `dev eth0` when the intent is to attach the VLAN to the physical interface.

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

nmcli connection add type vlan con-name vlan10 dev eth0 id 10

The `nmcli connection add` command with `type vlan` requires the `dev` option to specify the parent interface (eth0) and the `id` option to set the VLAN tag (10). The `con-name` assigns a name to the connection profile, and the resulting interface will be named automatically (e.g., eth0.10) unless overridden by `ifname`. This creates a VLAN interface that tags frames with ID 10 on the parent device eth0.

Answer analysis

Option-by-option breakdown

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

  • nmcli connection add type vlan con-name vlan10 ifname eth0 id 10

    Why it's wrong here

    The correct parameter is 'dev', not 'ifname'.

  • nmcli connection add type vlan con-name vlan10 dev eth0 id 10

    Why this is correct

    This is the correct syntax to create a VLAN connection on eth0 with ID 10.

  • nmcli device add vlan con-name vlan10 dev eth0 id 10

    Why it's wrong here

    'nmcli device add' is not a valid command.

  • nmcli connection add type vlan con-name vlan10 ifname eth0.10

    Why it's wrong here

    This would create a connection with a specific ifname but not necessarily a VLAN.

Visual reference

Switch VLAN 10 Sales (192.168.10.0/24) PC-A PC-B VLAN 20 HR (192.168.20.0/24) PC-C PC-D Router VLANs isolate traffic — inter-VLAN routing requires a Layer 3 device

About these practice questions

Courseiva writes every LFCS question from scratch — 507 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or 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 LFCS practice question is part of Courseiva's free Linux Foundation 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 LFCS exam.