A Step-by-Step Guide to Configuring DHCP on Windows Server 2016 Using GUI and PowerShell.
Z GUI
1. Teči the DHCP console from the apps list. Pojdite na IPv4\Server Options. There we config Server options for all scopes;
2. Desni gumb miške click at Server Options in kliknite Configure Options;
3. Select option 006 DNS Servers, vstopiti an IP address, in kliknite Dodaj;
4. Select option 015 DNS Domain Name, enter the domain name, in kliknite v redu;
5. New options added;
6. Desni gumb miške click at IPv4 in kliknite New Scope;
7. Kliknite Naslednji;
8. Vnesite Ime (and if you wish Opis), in kliknite Naslednji;
9. Vnesite the Start IP address, End IP address, in Subnet mask, in kliknite Naslednji;
10. On this page, you may exclude the IP range from DHCP. Kliknite Naslednji;
11. Set Lease Duration in kliknite Naslednji;
12. You may select ja and configure Scope Options for this scope. izberem št, kliknite Naslednji;
13. Kliknite Končaj;
14. Scope created, but we must Activate it;
15. Desni gumb miške click at the scope and click Activate;
16. Scope activated and worked!
17. If you Desni gumb miške kliknite na Leased IP Address, you may Add to the reservation Add to the filter, or even Izbriši it;
S PowerShell
1. Teči PowerShell as Administrator. To get active scopes enter:
Get-DhcpServerv4Scope -cn <dhcp server name> | select scopeid, name, description
2. To add new scope, vstopiti:
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 Najboljše prakse 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.