Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren

Het doel van dit artikel is om de configuratie van de DHCP-service voor VXLAN BGP EVPN en DFA fabric te vereenvoudigen met behulp van Microsoft Windows Server 2016/2019.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
In de officiële documentatie is de DHCP-service op basis van Microsoft Windows Server 2012 voor de fabric geconfigureerd als een SuperScope met daarin een Loopback-pool (het hoogtepunt van deze pool is de uitsluiting van alle IP-adressen van de pool uit de pool (uitgesloten IP-adres = pool)) en pools voor het uitgeven van IP-adressen voor echte netwerken (hier is het hoogtepunt - beleid is geconfigureerd - waarin DHCP Relay Circuit ID wordt gefilterd en deze DHCP-relay Circuit ID bevat de VNI voor het netwerk, d.w.z. voor een andere pool deze DHCP Relay Circuit-ID zal enigszins afwijken).

To configure DHCP on Windows server. 

1. Create a super scope. Within the super scope, create scope B, S1, S2, S3, …, Sn for the subnet B and the subnets for each segment. 
2. In scope B,  specify the 'Exclusion Range' to be the entire address range (so that the offered address range must not be from this scope). 
3. For every segment scope Si, specify a policy that matches on Agent Circuit ID with value of '0108000600XXXXXX', where '0108000600' is a fixed value for all segments, the 6 numbers "XXXXXX" is the segment ID value in hexadecimal. Also ensure to check the Append wildcard(*) check box. 
4. Set the policy address range to the entire range of the scope.

Dit artikel bevat antwoorden op de volgende vragen:


Inhoud

Introductie

Dit deel geeft een korte opsomming van alle initiële gegevens: Instructies voor het configureren van netwerkapparatuur, RFC's die worden gebruikt in DHCP-pakketten in eVPN-fabrieken, de evolutie van de DHCP-serverinstellingen op Microsoft Windows Server 2012 in de Cisco-documentatie worden ter referentie verstrekt. Evenals korte informatie over Superscope en Policy in de DHCP-service op Microsoft Windows Servers.

Hoe DHCP Relay te configureren op een VXLAN BGP EVPN, DFA-fabric

Het configureren van DHCP Relay op een VXLAN BGP EVPN-fabric is niet het hoofdonderwerp van dit artikel, omdat het vrij eenvoudig is. Ik geef links naar documentatie en een spoiler over instellingen op netwerkapparatuur.

Voorbeeld van het instellen van DHCP Relay op Nexus 9000V v9.2(3)

service dhcp
ip dhcp relay
ip dhcp relay information option
ip dhcp relay information option vpn
interface loopback10
  vrf member VRF1
  ip address 10.120.0.1/32 tag 1234567
interface Vlan12
  no shutdown
  vrf member VRF1
  no ip redirects
  ip address 10.120.251.1/24 tag 1234567
  no ipv6 redirects
  fabric forwarding mode anycast-gateway
  ip dhcp relay address 10.0.0.5
  ip dhcp relay source-interface loopback10

RFC's die zijn geïmplementeerd bij de werking van de DHCP Relay-service in VXLAN BGP EVPN-fabrics

RFC#6607: Suboptie 151(0x97) - Selectie van virtueel subnet

•	Sub-option 151(0x97) - Virtual Subnet Selection (Defined in RFC#6607)
Used to convey VRF related information to the DHCP server in an MPLS-VPN and VXLAN EVPN multi-tenant environment.

De “naam” van de VRF waarin de client zich bevindt, wordt verzonden.

RFC#5107: Suboptie 11(0xb) - Server-ID negeren

•	Sub-option 11(0xb) - Server ID Override (Defined in RFC#5107.) 
The server identifier (server ID) override sub-option allows the DHCP relay agent to specify a new value for the server ID option, which is inserted by the DHCP server in the reply packet. This sub-option allows the DHCP relay agent to act as the actual DHCP server such that the renew requests will come to the relay agent rather than the DHCP server directly. The server ID override sub-option contains the incoming interface IP address, which is the IP address on the relay agent that is accessible from the client. Using this information, the DHCP client sends all renew and release request packets to the relay agent. The relay agent adds all of the appropriate sub-options and then forwards the renew and release request packets to the original DHCP server. For this function, Cisco’s proprietary implementation is sub-option 152(0x98). You can use the ip dhcp relay sub-option type cisco command to manage the function.

De optie wordt gebruikt om ervoor te zorgen dat de client een verzoek verzendt om de adreslease te vernieuwen naar het IP-adres dat in deze optie wordt gebruikt. (Op Cisco VXLAN BGP is EVPN het standaard gateway-Anycast-adres van de client.)

RFC#3527: Suboptie 5(0x5) - Linkselectie

Sub-option 5(0x5) - Link Selection (Defined in RFC#3527.) 

The link selection sub-option provides a mechanism to separate the subnet/link on which the DHCP client resides from the gateway address (giaddr), which can be used to communicate with the relay agent by the DHCP server. The relay agent will set the sub-option to the correct subscriber subnet and the DHCP server will use that value to assign an IP address rather than the giaddr value. The relay agent will set the giaddr to its own IP address so that DHCP messages are able to be forwarded over the network. For this function, Cisco’s proprietary implementation is sub-option 150(0x96). You can use the ip dhcp relay sub-option type ciscocommand to manage the function.

Adres van het netwerk waarvan de client een IP-adres nodig heeft.

Evolutie van Cisco-documentatie met betrekking tot het configureren van DHCP op Microsoft Windows Server 2012

Ik heb deze sectie opgenomen omdat er een positieve trend is aan de kant van de leverancier:

Nexus 9000 VXLAN-configuratiehandleiding 7.3

De documentatie laat alleen zien hoe u DHCP Relay op netwerkapparatuur configureert.

Een ander artikel werd gebruikt om DHCP op Windows Server 2012 te configureren:

Microsoft Windows Server 2012 configureren om DHCP-services te bieden in een eVPN-scenario (VXLAN, Cisco One Fabric, enz.)

Dit artikel geeft aan dat elk netwerk/VNI een eigen SuperScope-bundel en een eigen set Loopback-adressen nodig heeft:

If multiple DHCP Scopes are required for multiple subnets, you need to create one LoopbackX per subnet/vlan on all LEAFS and create a superscope with a loopbackX range scope and actual client IP subnet scope per vlan.

Nexus 9000 VXLAN-configuratiehandleiding 9.3

Windows 2012 Server-instellingen toegevoegd aan de documentatie voor het instellen van netwerkapparatuur. Voor alle gebruikte adrespools is één SuperScope per datacenter vereist en deze SuperScope vormt de grens van het datacenter:

Create Superscope for all scopes you want to use for Option 82-based policies.
Note
The Superscope should combine all scopes and act as the administrative boundary.

Cisco dynamische fabric-automatisering

Alles wordt heel kort uitgelegd:

Let us assume the switch is using the address from subnet B (it can be the backbone subnet, management subnet, or any customer designated subnet for this purpose) to communicate with the Windows DHCP server. In DFA we have subnets S1, S2, S3, …, Sn for segment s1, s2, s3, …, sn. 

To configure DHCP on Windows server. 

1. Create a super scope. Within the super scope, create scope B, S1, S2, S3, …, Sn for the subnet B and the subnets for each segment. 
2. In scope B,  specify the 'Exclusion Range' to be the entire address range (so that the offered address range must not be from this scope). 
3. For every segment scope Si, specify a policy that matches on Agent Circuit ID with value of '0108000600XXXXXX', where '0108000600' is a fixed value for all segments, the 6 numbers "XXXXXX" is the segment ID value in hexadecimal. Also ensure to check the Append wildcard(*) check box. 
4. Set the policy address range to the entire range of the scope.

DHCP in Microsoft Windows Server (superscope & beleid)

Superscope

Superscope is an administrative feature of a DHCP server that can be used to group multiple scopes as a single administrative entity. Superscope allows a DHCP server to provide leases from more than one scope to clients on a single physical network. Scopes added to a superscope are called member scopes.

Wat is SuperScope - het is een functionaliteit waarmee u verschillende groepen IP-adressen kunt combineren in één administratieve eenheid. Om te adverteren voor gebruikers op hetzelfde fysieke netwerk (in hetzelfde VLAN) IP-adressen uit verschillende pools. Als het verzoek bij een pool van adressen binnenkomt als onderdeel van een SuperScope, kan de klant een adres krijgen van een andere Scope die in deze SuperScope is opgenomen.

Beleid

The DHCP Server role in Windows Server 2012 introduces a new feature that allows you to create IPv4 policies that specify custom IP address and option assignments for DHCP clients based on a set of conditions.

The policy based assignment (PBA) feature allows you to group DHCP clients by specific attributes based on fields contained in the DHCP client request packet. PBA enables targeted administration and greater control of the configuration parameters delivered to network devices with DHCP.

Beleid – hiermee kunt u IP-adressen aan gebruikers toewijzen, afhankelijk van het type gebruiker of parameter. Cisco-technici gebruiken beleid in Windows Server 2012 om te filteren op VNI (Virtual Network Identifier).

Het grootste deel

Dit gedeelte bevat de resultaten van het onderzoek, waarom het niet wordt ondersteund, hoe het werkt (logica), wat er nieuw is en hoe dit nieuwe ons zal helpen.

Waarom wordt Microsoft Windows Server 2000/2003/2008 niet ondersteund?

Microsoft Windows Server 2008 en eerdere versies verwerken optie 82 niet en het retourpakket wordt verzonden zonder optie 82.

Win2k8 R2 DHCP-probleem met Option82

  1. Het verzoek van de client wordt verzonden naar Broadcast (DHCP Discover).
  2. De apparatuur (Nexus) stuurt het pakket naar de DHCP-server (DHCP Discover + Option 82).
  3. DHCP Server ontvangt het pakket, verwerkt het en stuurt het terug, maar zonder optie 82. (DHCP-aanbieding – zonder optie 82)
  4. Het apparaat (Nexus) ontvangt een pakket van de DHCP-server. (DHCP-aanbieding) Maar stuurt dit pakket niet naar de eindgebruiker.

Sniffer-gegevens - op Windows Server 2008 en op de DHCP-clientWindows Server 2008 ontvangt een verzoek van netwerkapparatuur. (Optie 82 is aanwezig in de lijst)

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Windows Server 2008 verzendt het antwoord naar de netwerkapparatuur. (Optie 82 staat niet als optie vermeld in het pakket)
Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Verzoek van de client - DHCP Discover is aanwezig en DHCP Offer ontbreekt
Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Statistieken over netwerkapparatuur:

NEXUS-9000V-SW-1# show ip dhcp relay statistics 
----------------------------------------------------------------------
Message Type             Rx              Tx           Drops  
----------------------------------------------------------------------
Discover                  8               8               0
Offer                     8               8               0
Request(*)                0               0               0
Ack                       0               0               0
Release(*)                0               0               0
Decline                   0               0               0
Inform(*)                 0               0               0
Nack                      0               0               0
----------------------------------------------------------------------
Total                    16              16               0
----------------------------------------------------------------------

DHCP L3 FWD:
Total Packets Received                           :         0
Total Packets Forwarded                          :         0
Total Packets Dropped                            :         0
Non DHCP:
Total Packets Received                           :         0
Total Packets Forwarded                          :         0
Total Packets Dropped                            :         0
DROP:
DHCP Relay not enabled                           :         0
Invalid DHCP message type                        :         0
Interface error                                  :         0
Tx failure towards server                        :         0
Tx failure towards client                        :         0
Unknown output interface                         :         0
Unknown vrf or interface for server              :         0
Max hops exceeded                                :         0
Option 82 validation failed                      :         0
Packet Malformed                                 :         0
Relay Trusted port not configured                :         0
DHCP Request dropped on MCT                      :         0
*  -  These counters will show correct value when switch 
receives DHCP request packet with destination ip as broadcast
address. If request is unicast it will be HW switched
NEXUS-9000V-SW-1#

Waarom is configuratie zo moeilijk in Microsoft Windows Server 2012?

Microsoft Windows Server 2012 ondersteunt RFC#3527 nog niet (Optie 82 Suboptie 5(0x5) - Linkselectie)
Maar de beleidsfunctionaliteit is al geïmplementeerd.

Hoe het werkt:

  • Microsoft Windows Server 2012 heeft een superpool (SuperScope) met Loopback-adressen en pools voor echte netwerken.
  • De selectie van de pool voor het uitgeven van een IP-adres valt onder SuperScope, aangezien het antwoord afkomstig was van DHCP Relay met het Loopback Source-adres opgenomen in SuperScope.
  • Met behulp van Beleid selecteert het verzoek uit Superscope dat lidbereik waarvan de VNI is opgenomen in Optie 82 Suboptie 1 Agentcircuit-ID. (“0108000600”+ 24 bits VNI + 24 bits waarvan de waarden mij onbekend zijn, maar de sniffer geeft waarden van 0 aan in dit veld.)

Hoe wordt de installatie vereenvoudigd in Microsoft Windows Server 2016/2019?

Microsoft Windows Server 2016 implementeert RFC#3527-functionaliteit. Dat wil zeggen dat Windows Server 2016 het juiste netwerk kan herkennen aan de hand van het kenmerk Optie 82 Suboptie 5(0x5) - Linkselectie

Er rijzen meteen drie vragen:

  • Kunnen we zonder Superscope?
  • Kunnen we het zonder beleid doen en VNI omzetten naar hexadecimale vorm?
  • Kunnen we zonder Scope for Loopback DHCP Source-adressen?

Q. Kunnen we zonder Superscope?
A. Ja, er kan direct ruimte gecreëerd worden op het gebied van IPv4-adressen.
Q. Kunnen we het zonder beleid doen en VNI omzetten naar hexadecimale vorm?
A. Ja, netwerkselectie is gebaseerd op Optie 82 Suboptie 0x5,
Q. Kunnen we zonder Scope for Loopback DHCP Source-adressen?
A. Nee we kunnen niet. Omdat Microsoft Windows Server 2016/2019 bescherming biedt tegen kwaadaardige DHCP-verzoeken. Dat wil zeggen dat alle verzoeken van adressen die zich niet in de DHCP-serverpool bevinden, als schadelijk worden beschouwd.

Opties voor DHCP-subnetselectie

 Note
All relay agent IP addresses (GIADDR) must be part of an active DHCP scope IP address range. Any GIADDR outside of the DHCP scope IP address ranges is considered a rogue relay and Windows DHCP Server will not acknowledge DHCP client requests from those relay agents.

A special scope can be created to "authorize" relay agents. Create a scope with the GIADDR (or multiple if the GIADDR's are sequential IP addresses), exclude the GIADDR address(es) from distribution, and then activate the scope. This will authorize the relay agents while preventing the GIADDR addresses from being assigned.

Die. Om een ​​DHCP-pool voor een VXLAN BGP EVPN-fabriek op Microsoft Windows Server 2016/2019 te configureren, heeft u alleen het volgende nodig:

  • Maak een pool voor Source Relay-adressen.
  • Maak een pool voor clientnetwerken

Wat is niet nodig (maar kan worden geconfigureerd en het zal werken en het werk niet hinderen):

  • Beleid maken
  • Maak SuperScope

VoorbeeldVoorbeeld van het opzetten van een DHCP-server (er zijn 2 echte DHCP-clients - de clients zijn verbonden met de VXLAN-structuur)

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Voorbeeld van het opzetten van een gebruikerspool:

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Een voorbeeld van het opzetten van een gebruikerspool (beleid wordt geselecteerd - om te bewijzen dat beleid niet is gebruikt voor de juiste werking van de pool):

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Een voorbeeld van het configureren van een pool voor Source DHCP Relay-adressen (het bereik van adressen voor uitgifte komt volledig overeen met uitsluiting van de adrespool):

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Een DHCP-service instellen op Microsoft Windows Server 2019

Een pool configureren voor Loopback-adressen (bron) voor DHCP Relay.

We creëren een nieuwe pool (Scope) in de IPv4-ruimte.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Wizard voor het maken van zwembaden. "Volgende >"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Configureer de naam van het zwembad en de beschrijving van het zwembad.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Stel het bereik van IP-adressen voor Loopback en het masker voor de pool in.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Uitzonderingen toevoegen. Het uitsluitingsbereik moet exact overeenkomen met het zwembadbereik.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Huurtijd. "Volgende >"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Vraag: Wilt u nu de DHCP-opties configureren (DNS, WINS, Gateway, Domein) of zult u dit later doen? Het zou sneller zijn om nee te antwoorden en vervolgens de pool handmatig te activeren. Of ga naar het einde zonder enige informatie in te vullen en activeer de pool aan het einde van de wizard.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
We bevestigen dat de opties niet zijn geconfigureerd en dat de pool niet is geactiveerd. "Finish"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Wij activeren het zwembad handmatig. — Selecteer Bereik en in het contextmenu — selecteer “Activeren”.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren

We creëren een pool voor gebruikers/servers.

We creëren een nieuw zwembad.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Wizard voor het maken van zwembaden. "Volgende >"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Configureer de naam van het zwembad en de beschrijving van het zwembad.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Stel het bereik van IP-adressen voor Loopback en het masker voor de pool in.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Uitzonderingen toevoegen. (Standaard zijn er geen uitzonderingen vereist) "Volgende >"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Huurtijd. "Volgende >"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Vraag: Wilt u nu de DHCP-opties configureren (DNS, WINS, Gateway, Domein) of zult u dit later doen? Laten we het nu instellen.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Configureer het standaard gateway-adres.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
We configureren het domein en de DNS-serveradressen.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Configuratie van IP-adressen van WINS-servers.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Scope-activering.

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren
Het zwembad is geconfigureerd. "Finish"

Microsoft Windows Server 2016/2019 configureren om DHCP-services voor VXLAN (DFA) te leveren

Conclusie

Het gebruik van Windows Server 2016/2019 vermindert de complexiteit van het opzetten van een DHCP-server voor een VXLAN-fabric (of een andere fabric). (Het is niet nodig om speciale links naar IT-specialisten over te dragen: Netwerk/Agent Circuit ID om filters te registreren.)

Zal de configuratie voor Windows Server 2012 werken op nieuwe 2016/2019-servers - ja, het zal werken.

Dit document bevat verwijzingen naar 2 versies: 7.X en 9.3. Dit komt door het feit dat versie 7.0(3)I7(7) een door Cisco voorgestelde release is, en versie 9.3 de meest innovatieve is (ondersteunt zelfs Multicast via VXLAN Multisite).

Lijst met bronnen

  1. Nexus 9000 VXLAN-configuratiehandleiding 7.x
  2. Nexus 9000 VXLAN-configuratiehandleiding 9.3
  3. DFA (Cisco Dynamic Fabric-automatisering)
  4. Microsoft Windows Server 2012 configureren om DHCP-services te bieden in een eVPN-scenario (VXLAN, Cisco One Fabric, enz.)
  5. 3.4 DHCP-superscopen
  6. Inleiding tot DHCP-beleid
  7. Win2k8 R2 DHCP-probleem met Option82
  8. Opties voor DHCP-subnetselectie

Bron: www.habr.com

Voeg een reactie