SkillPilotAI

Network roles of Windows Server

Windows Server provides its network services as roles: DNS Server, DHCP Server, Remote Access (VPN/NAT/routing) and Hyper-V with its virtual switch, plus the IPAM feature and NIC teaming. Knowing which role does which job is the base for designing a branch or data-centre server.

240.1 Why is it used?

  • Setting IP and DNS by hand on 20 branch laptops is slow and error-prone: DHCP + DNS automate it.
  • Many branches with their own DHCP/DNS servers need one central view: IPAM.
  • Home users and branch PCs need VPN, NAT and routing: Remote Access (RRAS).
  • VMs need networking and NIC failover: Hyper-V virtual switch + SET teaming.

240.2 Role, role service, feature

TermMeaningExample
RoleA big server jobDNS Server, DHCP Server, Hyper-V
Role serviceOne part of a roleRouting inside Remote Access
FeatureSupporting pieceManagement tools, IPAM
Install / checkServer Manager wizard or cmdletsInstall-WindowsFeature / Get-WindowsFeature

240.3 How DNS + DHCP serve a branch

New laptop in the branch
  1. 1.Laptop pc1 boots and broadcasts DHCP Discover (src 0.0.0.0, dst 255.255.255.255, UDP 67)

  2. 2.srv1 (DNS + DHCP, 192.168.201.10) offers 192.168.201.121 with DNS .10 and domain branch.lab

  3. 3.Laptop asks DNS (UDP 53) for fileserver

  4. 4.Same server answers A 192.168.201.20

  5. 5.Laptop connects to the file server over SMB

DHCP gives the IP; DNS turns names into IPs

240.4 IPAM, Remote Access, Hyper-V switch, teaming

IPAM: one console for many servers
  1. 1.IPAM server discovers the DHCP and DNS servers of the network

  2. 2.DHCP 1 (Branch A) and DHCP 2 (Branch B) send scopes + leases

  3. 3.DNS 1 (head office) sends zones

  4. 4.Admin manages all branches in one IPAM console

  • Remote Access (RRAS) role services: DirectAccess and VPN, Routing, Web Application Proxy.
  • VPN: a home laptop builds an encrypted tunnel to the RRAS server and reaches the file server 192.168.201.20 as if in the office.
  • NAT: a branch PC 192.168.201.50 going to the internet gets the RRAS public address as source.
  • Routing: routes traffic between subnets.
Virtual switchWho can talkTypical use
ExternalVMs, host and the physical LAN (bound to a physical NIC)VMs that need the office network
InternalVMs and the host, not the outside LANHost-VM lab, NAT setups
PrivateOnly VMs; even the host is outsideIsolated test networks
  • SET (Switch Embedded Teaming) builds the NIC team inside the Hyper-V virtual switch: if NIC1's cable is pulled, traffic moves to NIC2 via Switch 2.
  • Since Windows Server 2022 the Hyper-V switch cannot bind to an LBFO team, so Hyper-V hosts use SET.

240.5 Windows 11: is Get-WindowsFeature there? (real)

PowerShell
Get-Command Get-WindowsFeature -ErrorAction SilentlyContinue$null -eq (Get-Command Get-WindowsFeature -ErrorAction SilentlyContinue)Get-Command Get-WindowsFeatureGet-Module -ListAvailable ServerManager | Measure-Object
Output
$ Get-Command Get-WindowsFeature -ErrorAction SilentlyContinue $ $null -eq (Get-Command Get-WindowsFeature -ErrorAction SilentlyContinue)True$ Get-Command Get-WindowsFeatureGet-Command : The term 'Get-WindowsFeature' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.$ Get-Module -ListAvailable ServerManager | Measure-ObjectCount    : 0
  • Get-WindowsFeature is in the ServerManager module, which exists only on Windows Server.
  • Get-WindowsOptionalFeature -Online was not run: it needs admin and would list the office image's features.

240.6 Get-WindowsFeature output and role names (docs)

PowerShell
# Microsoft Learn: install DFS ReplicationGet-WindowsFeature | Where-Object { $_.Name -eq "FS-DFS-Replication" -or $_.Name -eq "RSAT-DFS-Mgmt-Con" }# Get-WindowsFeature docs, Example 4Get-WindowsFeature -ComputerName Server01 | Where Installed
Output
Display Name                                            Name                       Install State------------                                            ----                       -------------        [X] DFS Replication                             FS-DFS-Replication             Installed            [X] DFS Management Tools                    RSAT-DFS-Mgmt-Con              Installed
  • [X] = installed; an indented name is a sub-feature.
Role / featureTypeName for the cmdlets
DNS ServerRoleDNS
DHCP ServerRoleDHCP
IP Address Management (IPAM)FeatureIPAM
Remote AccessRoleRemoteAccess
DirectAccess and VPN (RAS)Role service of Remote AccessDirectAccess-VPN
RoutingRole service of Remote AccessRouting
Hyper-VRoleHyper-V
PowerShell
Install-WindowsFeature -Name DNSInstall-WindowsFeature DHCP -IncludeManagementToolsInstall-RemoteAccess -VpnType RoutingOnly
  • -RoutingOnly turns RRAS into a plain LAN router. These were not run on this PC.

240.7 Linux equivalent lab (dnsmasq = DNS + DHCP)

Docker lab network 192.168.201.0/24: srv1 runs dnsmasq, one process giving both roles; no-resolv keeps every query inside the lab.

Output
# DNS role: zone branch.labno-resolvdomain=branch.labhost-record=fileserver.branch.lab,192.168.201.20host-record=printer.branch.lab,192.168.201.30# DHCP role: one scope + optionsdhcp-range=192.168.201.100,192.168.201.150,255.255.255.0,1hdhcp-option=option:routerdhcp-option=option:dns-server,192.168.201.10dhcp-option=option:domain-name,branch.lab
Output
[server]$ dnsmasq --version | head -1Dnsmasq version 2.90  Copyright (c) 2000-2024 Simon Kelley[server]$ netstat -lnupProto Local Address           Foreign Addressudp   192.168.201.10:53       0.0.0.0:*udp   0.0.0.0:67              0.0.0.0:*
Terminal
udhcpc -i eth0 -n -q -t 3 -x hostname:pc1 -s /tmp/hook.ship -4 -br addr show eth0cat /tmp/dnsmasq.leases        # on the servergrep DHCP /tmp/dnsmasq.log     # on the server
Output
udhcpc: started, v1.36.1udhcpc: broadcasting discoverudhcpc: broadcasting select for 192.168.201.121, server 192.168.201.10udhcpc: lease of 192.168.201.121 obtained from 192.168.201.10, lease time 3600lease: ip=192.168.201.121 mask=24 dns=192.168.201.10 domain=branch.lab router=none lease=3600 serverid=192.168.201.10eth0@if2049      UP             192.168.201.121/241794247448 32:01:2e:8b:fd:bb 192.168.201.121 pc1 01:32:01:2e:8b:fd:bbdnsmasq-dhcp[32]: 2985281032 DHCPDISCOVER(eth1) 32:01:2e:8b:fd:bbdnsmasq-dhcp[32]: 2985281032 DHCPOFFER(eth1) 192.168.201.121 32:01:2e:8b:fd:bbdnsmasq-dhcp[32]: 2985281032 DHCPREQUEST(eth1) 192.168.201.121 32:01:2e:8b:fd:bbdnsmasq-dhcp[32]: 2985281032 DHCPACK(eth1) 192.168.201.121 32:01:2e:8b:fd:bb pc1
  • DISCOVER, OFFER, REQUEST, ACK = the four DORA steps; router=none so there is no way out of the lab.
Terminal
dig @192.168.201.10 fileserver.branch.lab +shortdig @192.168.201.10 pc1.branch.lab +noall +answerdig @192.168.201.10 -x 192.168.201.20 +shortdig @192.168.201.10 example.com | grep status
Output
192.168.201.20pc1.branch.lab.		0	IN	A	192.168.201.121fileserver.branch.lab.;; ->>HEADER<<- opcode: QUERY, status: REFUSED, id: 51205
  • pc1 resolves although nobody added it: dnsmasq registered the name when it gave the lease.
  • Reverse lookup works; example.com is REFUSED because the server only knows lab names.

240.8 Common mistakes

  • Laptops get an IP but names fail: check the DNS Server role and the scope's DNS option, not DHCP.
  • Expecting Get-WindowsFeature / server roles on Windows 11: use RSAT to manage servers remotely.
  • Calling IPAM a role: the docs list it as a feature.
  • Binding a Hyper-V switch to an LBFO team on Windows Server 2022+: use SET.

240.9 Interview tips

  • Branch server: DNS Server + DHCP Server for automatic IPs and names.
  • IPAM manages many DHCP/DNS servers centrally.
  • Remote Access gives VPN, NAT and routing (RRAS).
  • Hyper-V switch types External / Internal / Private; SET teaming for NIC failover on Hyper-V hosts.