- Turn the tables on your organization with Adaxes 2018.1's Web Interface and reporting capabilities - Thu, Sep 20 2018
- Review: Softerra Adaxes - Automating Active Directory management - Thu, Jun 4 2015
- Azure Multi-Factor Authentication - Part 8: Delegating Administration - Tue, Apr 28 2015
The most important built-in configuration tool is sconfig.cmd. The easiest way to give you a quick heads-up for this tool is to call it the command line equivalent of Server Manager on Server with a GUI installations and Full Installations of Windows Server, except for the remote management and multi-server management capabilities.
It allows you to easily change the hostname, IPv4 addressing, domain membership, time and time zone, Windows Update, and all the other settings you would like to change on a Windows Server installation after you just installed it. To run it, simply type sconfig.cmd at the command prompt and hit Enter:
Another great configuration utility in Server Core installations is SCRegEdit.wsf in the C:\Windows\System32 folder. This tool gives you the options to enable or disable Remote Desktop and configure Windows Update settings.
Command line tools ^
Besides sconfig.cmd, you have the full arsenal of command line tools available on Server Core. You can quickly change the most rudimentary settings with sconfig.cmd, but if you want to configure your server using scripts, you can still perform most of these actions through the usual suspects netdom.exe (to change the hostname and join an Active Directory domain), netsh.exe (to change IP addressing), and net.exe (to add or remove user accounts).
Of course, with the built-in command line tools, you can also configure settings beyond sconfig.cmd, like the Windows firewall (netsh), driver installation (pnputil and drvinst), RAID volumes (diskraid), and services (sc).
For networking troubleshooting, arp, nbtstat, netstat, ping, pathping, route, and tracert are available. For file handling, you can put cacls, icacls, attrib, cipher, compact, expand, takeown, and robocopy to good use. Need to claim disk space on other drives? Slap on some diskpart, format, fsutil, and label. Defrag often, unless you’re running on SSDs. Lost? No worries. Simply use hostname and whoami to get you sorted. And I’m still leaving half of the tools out.
Of course, between a Server with a GUI installation and a Server Core installation, some command line tools are missing. Most notably, ServerManagerCmd.exe is not available on Server Core, since the whole of Server Manager is not available.
Unless you’ve been living under a rock for the past few years, you might have heard about this new command line shell in Windows, called PowerShell. Exchange Server was the first product to embrace this new technology for its management needs, and since then most of the Microsoft product teams have followed its example.
PowerShell is identical between all installations of Windows Server 2012: Server Core installations, Minimal Server installations, and Server with a GUI installations all offer the same built-in PowerShell modules and cmdlets. Also, per Server Role and Feature, independent of the installation type, the PowerShell modules and cmdlets are identical.
PowerShell, therefore, is the recommended command line shell to base scripts on. These scripts can be run on all Windows Server installations and on Windows clients (depending on the availability of the PowerShell modules).
The PowerShell Integrated Scripting Environment (ISE) is the recommended tool to build scripts in, since it offers several tools to help you. However, the PowerShell ISE, itself, is a graphical tool and is not available on Server Core installations.
To start using PowerShell, simply type powershell at the command line:
PowerShell on Server Core
Graphical tools ^
Until reading up to this point, you might have the impression that Server Core is all about command line tools. But, this is not the case. Server Core installations of Windows Server 2012 offer several graphical tools:
It’s not easy to get an overview of a Windows installation from the command line. Systeminfo.exe might get you up to speed from the command line, but if you really want to know about the system and get a comprehensive view of your hardware, system components, and software environment, start up MSInfo32.exe from the command line. Now, you will have MSInfo32.exe, just like you would on any other system.
Within the SYSTEM32 folder of your Server Core installation, another great inventory tool is available: GatherNetworkInfo.vbs. As its name suggests, you can use it to dump the networking information of the installation into a file of your choice.
So how would you read such a file? Simple. Notepad.exe is available to you. You can use it as you would on a Server with a GUI, and this allows for a neat trick. If you liked to work within the Windows Explorer in previous versions of Windows, you can use the Open… command from the File menu (Ctrl+O) to get the same functionality. Also, it allows for right-clicking files to get their properties:
Notepad on Server Core
Regedit.exe and Regedt32.exe
Sometimes you really need to dig into the core of the operating system. Just as on a Server with a GUI, you can use the Registry Editor on a Server Core installation. This allows for easy manipulation of even the minutest setting in the operating system. Of course, you can also use secedit.exe to import Group Policy settings packages, allowing for easy manipulation of a series of registry settings.
Control Panel applets
Alas, even with the full arsenal of command line and graphical tools, some things cannot be achieved. This is why Microsoft has included Control Panel applets on Server Core installations. Although you cannot have the Control Panel view in Server Core installations, you can still run the following Control Panel applets from the command line:
To change the time and time zone on a Server Core installation, you can use timedate.cpl. This true Control Panel applet allows for all the usual settings, including configuring servers to synchronize time.
To change regional settings on a Server Core installation, you can use intl.cpl. It allows for changing time and date formats, currency settings, and the location of the server. There’s also the option to copy your settings to the logon screen so they apply to all system accounts and new users.
In many virtual environments, where Server Core installations are used as Hyper-V hosts, shared storage is available through the iSCSI protocol. On Windows Server 2008-based Server Core installations, iscsicli.exe was the only tool available to connect to this storage. Since Windows Server 2008 R2, however, you can use iscsicpl.exe to connect to shared storage over iSCSI.
Now that we know the tools at our disposal, it’s time to put them to good use. How? I’ll show you how in the next part of this series!