A Step-by-Step Guide to Configuring DHCP on Windows Server 2016 Using GUI and PowerShell.
GUI-val
1. Fuss a DHCP console from the apps list. Navigáljon ide IPv4\Server Options. There we config Server options for all scopes;
2. Jobb egérgomb click at Server Options és kattintson Configure Options;
3. Select option 006 DNS Servers, belép an IP address, és kattintson Hozzáadás;
4. Select option 015 DNS Domain Name, enter the domain name, és kattintson rendben;
5. New options added;
6. Jobb egérgomb click at IPv4 és kattintson New Scope;
7. Kattintson Következő;
8. Belép Név (and if you wish Leírás), és kattintson Következő;
9. Belép the Start IP address, End IP address, és Subnet mask, és kattintson Következő;
10. On this page, you may exclude the IP range from DHCP. Kattintson Következő;
11. Set Lease Duration és kattintson Következő;
12. You may select Igen and configure Scope Options for this scope. I choose No, kattintson Következő;
13. Kattintson Befejez;
14. Scope created, but we must Activate azt;
15. Jobb egérgomb click at the scope and click Activate;
16. Scope activated and worked!
17. If you Jobb egérgomb kattintson Leased IP Address, you may Add to the reservation Add to the filter, or even Töröl azt;
PowerShell-lel
1. Fuss PowerShell as Administrator. To get active scopes enter:
Get-DhcpServerv4Scope -cn <dhcp server name> | select scopeid, name, description
2. To add new scope, belép:
Add-DhcpServerv4Scope -Name ‘<scope name>’ -StartRange <start IP Address> -EndRange <end IP Address> -SubnetMask <subnet mask> -Description ‘<description>’ –cn <dhcp server name>
3. Before scope delete Best Practices is run the command with WhatIf parameter:
Remove-DhcpServerv4Scope -ScopeId <scope id> -cn <dhcp server name> -WhatIf
4. Then run without the WhatIf parameter:
Remove-DhcpServerv4Scope -ScopeId <scope id> -cn <dhcp server name>
5. Scope removed.