šŸŽ“ BookMCQ
← Back to 22. Next Generation IP

šŸ“ IPv6 autoconfiguration stateless and stateful (13 MCQs)

Automatic Address Configuration in IPv6 Networks

IPv6 hosts can configure interface addresses and network parameters with limited manual intervention. Stateless Address Autoconfiguration, or SLAAC, uses router advertisements to learn prefixes and construct addresses locally. Stateful DHCPv6 can allocate addresses and provide configuration information through a server. These methods support different administrative needs, and a network may use SLAAC and DHCPv6 together rather than treating them as mutually exclusive.

Router Advertisements and DHCPv6 Roles

Routers send Router Advertisement messages containing prefix information, lifetimes, and flags that guide host configuration. With SLAAC, a host combines an advertised prefix with an interface identifier and performs Duplicate Address Detection. DHCPv6 uses client-server exchanges to supply addresses or other parameters. DHCPv6 may also operate statelessly to provide options while SLAAC forms the address.

The Host Configuration Sequence

A newly connected host first forms a link-local address and checks whether it is already in use. It listens for router advertisements or sends a Router Solicitation to prompt one. The host then processes advertised prefixes and flags, configures a suitable address, performs Duplicate Address Detection, and may contact a DHCPv6 server for managed addresses or additional parameters.

Comparing SLAAC and Stateful DHCPv6 in Practice

On a LAN advertising prefix 2001:DB8:10:1::/64 with autonomous configuration enabled, a host can create its own address from that prefix. In a managed network, the router may signal DHCPv6 use, and a server can lease an address and DNS settings. Both approaches still rely on Duplicate Address Detection before an address is used.

Combining Address Assignment with Other Network Parameters

SLAAC and DHCPv6 connect IPv6 addressing with router discovery, DNS configuration, and address-lifetime management. SLAAC reduces the need for per-host address allocation records, while stateful DHCPv6 gives administrators centralized assignment control. Stateless DHCPv6 can provide additional settings even when addresses are formed through SLAAC, making mixed configuration common in managed networks.

Misconceptions About SLAAC and DHCPv6

'SLAAC requires a DHCP server' is incorrect because the host forms an address from router-advertised prefix information. 'DHCPv6 always replaces router advertisements' is false because routers still provide essential on-link and default-router information. 'An assigned address is immediately assumed unique' is wrong; Duplicate Address Detection checks for conflicts. This distinction matters when reading configuration flags.

Distinguishing Stateless and Stateful Configuration

For examinations, compare where the address comes from, which device provides configuration, and how lifetimes are managed. Interpret router-advertisement flags, identify the role of DHCPv6, and describe Duplicate Address Detection. Remember that DHCPv6 may supply non-address parameters without assigning the interface address itself. Know which information is distributed locally and which is maintained centrally.

SLAAC and DHCPv6 Configuration Terms

  • SLAAC - Host forms addresses from advertised prefixes.
  • DHCPv6 - Client-server protocol for IPv6 configuration.
  • Router Advertisement - Message carrying prefix and router information.
  • DAD - Checks whether an address is duplicated.
  • Lifetime - Period an address remains preferred or valid.
  • Stateless - Configuration without server-maintained address leases.
4
Easy
6
Medium
3
Hard

šŸ“ All IPv6 autoconfiguration stateless and stateful MCQs

Q1. If a router receives a BGP UPDATE that lists its own AS number in the AS‑PATH, what should the router do with that update?

A.Drop the update āœ…
B.Accept and forward the update
C.Modify the AS‑PATH to remove its own AS
D.Log the update and ignore it
šŸ’” Difficulty: easy | āœ… Correct: A

šŸ“– Explanation: The router detects a loop because its own AS appears in the AS‑PATH. According to BGP loop‑prevention rules, the safest action is to discard the UPDATE, preventing the router from advertising a path that would create a routing loop.

Q2. An UPDATE arrives with ORIGIN set to value 2 and a high MULTI‑EXIT‑DISC metric. Compared to a route with ORIGIN value 1 and a lower MED, which attribute most directly makes the first route less preferred?

A.ORIGIN āœ…
B.MULTI‑EXIT‑DISCRIMINATOR
C.NEXT‑HOP
D.LOCAL‑PREF
šŸ’” Difficulty: medium | āœ… Correct: A

šŸ“– Explanation: BGP first evaluates the ORIGIN attribute; a value of 2 (EGP) is less preferred than a value of 1 (IGP). Because ORIGIN is examined before MED, the higher ORIGIN value causes the route to be less attractive regardless of the MED value.

Q3. When a BGP speaker receives an UPDATE that lacks a LOCAL‑PREF attribute, what default value does it assume for internal routes?

A.Assume 0
B.Assume 100 āœ…
C.Assume 0 only for eBGP
D.Assume 100 only for iBGP
šŸ’” Difficulty: medium | āœ… Correct: B

šŸ“– Explanation: For iBGP updates, the LOCAL‑PREF attribute is mandatory; if it is missing, the receiving router uses the default value of 100. This default ensures consistent preference handling across the autonomous system while external routes may omit the attribute.

Q4. An AS sets LOCAL‑PREF to 200 and MED to 50 for routes from a neighbor. A downstream AS sees two alternatives: Path X (LOCAL‑PREF 150, MED 30) and Path Y (LOCAL‑PREF 200, MED 70). Which path will be selected and why?

A.Path X
B.Path Y āœ…
C.Both equally
D.None
šŸ’” Difficulty: hard | āœ… Correct: B

šŸ“– Explanation: BGP first compares LOCAL‑PREF values; the higher value (200 for Path Y) outweighs the longer AS‑PATH or higher MED. Consequently, Path Y is preferred even though its MED is larger, because LOCAL‑PREF has higher decision‑process priority.

Q5. Compare the transitive nature of the ORIGIN attribute with that of the MULTI‑EXIT‑DISCRIMINATOR attribute. Which statement is accurate?

A.Both are transitive
B.Both are non‑transitive
C.ORIGIN is transitive and MED is not āœ…
D.ORIGIN is non‑transitive and MED is transitive
šŸ’” Difficulty: easy | āœ… Correct: C

šŸ“– Explanation: The ORIGIN attribute is a well‑known transitive attribute, meaning it is passed unchanged between ASes. In contrast, the MULTI‑EXIT‑DISCRIMINATOR (MED) is an optional non‑transitive attribute; it is not advertised beyond the neighboring AS.

Q6. What is the effect of erroneously setting the OPTIONAL bit on the LOCAL‑PREF attribute flag?

A.It would become optional and not passed between ASes āœ…
B.It would be ignored by all routers
C.It would be treated as a well‑known discretionary attribute still propagated
D.It would cause an attribute‑length error
šŸ’” Difficulty: medium | āœ… Correct: A

šŸ“– Explanation: LOCAL‑PREF is defined as a well‑known discretionary attribute. If the OPTIONAL bit is set, the attribute becomes malformed; compliant routers treat it as an unknown optional attribute and discard it, effectively preventing the value from being propagated.

Q7. Which statement correctly describes AS‑PATH handling in iBGP versus eBGP sessions?

A.AS‑PATH is stripped on iBGP
B.AS‑PATH is unchanged on iBGP
C.AS‑PATH is appended on eBGP only āœ…
D.AS‑PATH is never modified
šŸ’” Difficulty: medium | āœ… Correct: C

šŸ“– Explanation: During an eBGP exchange, the local AS number is appended to the AS‑PATH before the UPDATE is sent. In iBGP sessions, the AS‑PATH is left unchanged because the update is already within the same autonomous system, so no new AS number is added.

Q8. An administrator configures a router to prepend its own AS three times for routes from a neighbor and also sets LOCAL‑PREF to 250. How does this affect selection in a downstream AS that receives these routes alongside alternatives with shorter AS‑PATH but lower LOCAL‑PREF?

A.The prepended routes will always be preferred
B.The lower LOCAL‑PREF will outweigh the longer AS‑PATH āœ…
C.The decision will depend on the relative values of LOCAL‑PREF and AS‑PATH length
D.The routes will be discarded due to conflict
šŸ’” Difficulty: hard | āœ… Correct: B

šŸ“– Explanation: BGP first evaluates LOCAL‑PREF; the higher value (250) outranks a shorter AS‑PATH with a lower LOCAL‑PREF. Therefore, the downstream AS will select the prepended routes despite their longer AS‑PATH because LOCAL‑PREF has higher priority in the decision process.

Q9. Which ORIGIN attribute value is considered most trustworthy when selecting a route?

A.IGP (value 1) āœ…
B.EGP (value 2)
C.INCOMPLETE (value 3)
D.UNKNOWN (value 3)
šŸ’” Difficulty: easy | āœ… Correct: A

šŸ“– Explanation: The ORIGIN attribute ranks IGP (value 1) as the most reliable source, followed by EGP (value 2) and INCOMPLETE (value 3). Consequently, routes advertised with an IGP origin are preferred over those with higher‑value origins.

Q10. How can the MULTI‑EXIT‑DISCRIMINATOR (MED) attribute be used for inbound traffic engineering between two neighboring ASes?

A.Setting a lower MED on the preferred exit path āœ…
B.Setting a higher MED on the preferred exit path
C.Ignoring MED altogether
D.Using MED only for eBGP updates
šŸ’” Difficulty: medium | āœ… Correct: A

šŸ“– Explanation: By assigning a lower MED value to the preferred exit point, an AS signals its neighbor that this path should be favored for inbound traffic. The neighbor’s BGP decision process will select the path with the smallest MED when other attributes are equal.

Q11. What best describes how route reflectors treat the LOCAL‑PREF attribute in iBGP?

A.Route reflectors reset LOCAL‑PREF to the default
B.Route reflectors propagate LOCAL‑PREF unchanged āœ…
C.Route reflectors ignore LOCAL‑PREF
D.Route reflectors convert LOCAL‑PREF to MED
šŸ’” Difficulty: medium | āœ… Correct: B

šŸ“– Explanation: Route reflectors are designed to preserve the LOCAL‑PREF attribute when reflecting routes. They forward the attribute unchanged to client peers, ensuring that the original preference decisions made by the originating router remain effective throughout the iBGP topology.

Q12. An AS receives two routes to the same prefix: Route A (LOCAL‑PREF 100, ORIGIN IGP, AS‑PATH length 2) and Route B (LOCAL‑PREF 200, ORIGIN EGP, AS‑PATH length 1). Which route will BGP select and why?

A.Route A
B.Route B āœ…
C.Both are equal
D.Selection is random
šŸ’” Difficulty: hard | āœ… Correct: B

šŸ“– Explanation: BGP first compares LOCAL‑PREF values; the higher value (200 for Route B) wins regardless of ORIGIN or AS‑PATH length. Thus, Route B is selected even though it has a shorter AS‑PATH and a less preferred ORIGIN type.

Q13. Which attribute type number corresponds to the NEXT‑HOP attribute in BGP?

A.1
B.2
C.3 āœ…
D.4
šŸ’” Difficulty: easy | āœ… Correct: C

šŸ“– Explanation: In the BGP attribute type field, the NEXT‑HOP attribute is assigned type number 3. This well‑known mandatory attribute conveys the IP address of the next hop router for forwarding traffic toward the destination network.

šŸ”— Related Topics (MCQs)