Quick Reference for Server Core Tasks
Applies To: Windows Server 2012 R2, Windows Server 2012
This topic is a collection of common administrative tasks for Server Core servers that you can perform locally or remotely from a command prompt.
Whenever possible, Windows PowerShell commands are used and are styled thus: Get-NetIPConfiguration. When no Windows PowerShell equivalent is available, run the indicated command at an ordinary command prompt or a Windows PowerShell prompt. These command are styled thus: Netdom remove
Task |
Description |
---|---|
Configuration and installation |
|
Networking and firewall |
|
Updates and error reporting |
|
Services, processes, and performance |
|
Event logs |
|
Disk and file system |
|
Hardware |
Note
This topic includes sample Windows PowerShell cmdlets that you can use to automate some of the procedures described. For more information, see Using Cmdlets.
1.1. Configuration and installation
Task |
Steps |
---|---|
Set the local administrative password |
Run: Net user administrator * |
Join a computer to a domain |
Run Add-Computer For more information see Configure a Server Core Server |
Confirm that the domain has changed |
Run: set |
Remove a computer from a domain |
Run: Remove-Computer |
Add a user to the local Administrators group. |
Run: net localgroup Administrators /add <domain>\<username> |
Remove a user from the local Administrators group |
Run: net localgroup Administrators /delete <domain\username> |
Add a user to the local computer |
Run: net user <domain\user name> /add * |
Add a group to the local computer |
Run: net localgroup <group name> /add |
Change the name of a domain-joined computer |
Run Rename-Computer |
Confirm the new computer name |
Run: set c |
Change the name of a computer in a work group |
Run: Rename-Computer |
Disable paging file management |
Run: wmic computersystem where name="<computername>" set AutomaticManagedPagefile=False |
Configure the paging file |
Run: wmic pagefileset where name=”<path/filename>” set InitialSize=<initialsize>,MaximumSize=<maxsize> Where: path/filename is the path to and name of the paging file initialsize is the starting size of the paging file in bytes maxsize is the maximum size of the paging file in bytes |
Change to a static IP address |
|
Set a static DNS address |
|
Change to a DHCP-provided IP address from a static IP address |
|
Enter a product key |
Run slmgr.vbs –ipk <product key>, and then run slmgr.vbs –ato. For more information, see Configure a Server Core Server. |
Activate the server locally |
Run slmgr.vbs -ato |
Activate the server remotely |
|
Note
If Slmgr.vbs fails to activate the computer, the resulting error message advises you to run Slui.exe, along with the error code for more information. Slui.exe is not included in Server Core installations—it is available in <versions>.
1.2. Networking and firewall
Task |
Steps |
||
---|---|---|---|
Configure your server to use a proxy server. |
Run netsh Winhttp set proxy <servername>:<port number>
|
||
Configure your server to bypass the proxy for Internet addresses. |
Run netsh winttp set proxy <servername>:<port number>bypass-list="<local>" |
||
Display or modify IPSEC configuration. |
Run netsh ipsec |
||
Display or modify NAP configuration. |
Run netsh nap |
||
Display or modify IP-to-physical address translation. |
Run arp |
||
Display or configure the local routing table. |
Run route |
||
View or configure DNS server settings. |
Run nslookup |
||
Display protocol statistics and current TCP/IP network connections |
Run netstat |
||
Display protocol statistics and current TCP/IP connections using NetBIOS over TCP/IP (NBT). |
Run nbtstat |
||
Display hops for network connections. |
Run pathping |
||
Trace hops for network connections. |
Run tracert |
||
Display the configuration of the multicast router |
Run mrinfo |
||
Enable remote administration of the firewall. |
Run netsh advfirewall firewall set rule group=”Windows Firewall Remote Management” new enable=yes |
Note
See additional Windows PowerShell cmdlets for networking at https://technet.microsoft.com/library/hh826123, https://technet.microsoft.com/library/jj134956, and https://technet.microsoft.com/library/hh848620.
1.3. Updates and error reporting
Task |
Steps |
---|---|
Install an update |
Run wusa <update>.msu /quiet |
List installed updates |
Run systeminfo |
Remove an update |
|
Configure automatic updates |
|
Enable error reporting |
|
Participate in the Customer Experience Improvement Program (CEIP) |
|
1.4. Services, processes, and performance
Task |
Steps |
---|---|
List running services |
Run Get-Service |
Start a service |
Run Start-Service |
Stop a service |
Run Stop-Service |
Retrieve a list of running applications and associated processes |
|
Stop a process forcibly |
|
Start Task Manager |
Run taskmgr |
Manage the performance counters and logging with commands such as typeperf, logman, relog, tracerprt. |
1.5. Event logs
Use Get-EventLog and related cmdlets; see https://technet.microsoft.com/library/ee176846.
1.6. Disk and file system
Task |
Steps |
---|---|
Manage disk partitions |
For a complete list of commands, run diskpart /? |
Manage software RAID |
For a complete list of commands, run diskraid /? |
Manage volume mount points |
For a complete list of commands, run mountvol /? |
Defragment a volume |
For a complete list of commands, run defrag /? |
Convert a volume to the NTFS file system |
Run convert <volume letter> /FS:NTFS |
Compact a file |
For a complete list of commands, run compact /? |
Administer open files |
For a complete list of commands, run openfiles /? |
Administer VSS folders |
For a complete list of commands, run vssadmin /? |
Administer the file system |
For a complete list of commands, run fsutil /? |
Verify a file signature |
For a complete list of commands, run sigverif /? |
Take ownership of a file or folder |
For a complete list of commands, run icacls /? |
1.7. Hardware
Task |
Steps |
---|---|
Add a driver for a new hardware device |
|
Remove a driver for a hardware device |
|