Windows Server and PowerShell
Not every workload is on Linux. A company's payroll app runs on Windows Server with IIS, and its users sign in through Active Directory. When it breaks at night, you need to be as comfortable there as on web1.
The rule
On Windows, think services, PowerShell objects and CRLF line endings.
Windows Server runs workloads that are built on Microsoft's stack: Active Directory for users and machines, IIS for web apps, SQL Server, and many .NET applications. Modern servers are often installed as Server Core, with no desktop at all, so you manage them from the command line or remotely.
Services. Long-running programs are Windows services, the equivalent of systemd units. You list and control them with PowerShell:
Get-Service -Name W3SVC # IIS web service status
Restart-Service -Name W3SVC
Get-WinEvent -LogName System -MaxEvents 20 # recent system log entriesPowerShell passes objects, not text. On Linux, a pipe sends plain text and you cut columns out of it. In PowerShell each item is an object with named properties, so you sort and filter by name:
Get-Process | Sort-Object CPU -Descending | Select-Object -First 5 Name, CPUPowerShell commands follow a Verb-Noun pattern: Get-, Set-, Start-, Stop-, Restart-, New-, Remove-. PowerShell also runs on Linux and macOS today.
Line endings. Windows text files end lines with carriage return plus line feed (CRLF); Linux uses only line feed (LF). A shell script saved with CRLF on Windows fails on Linux with a confusing bad interpreter error, because the invisible \r becomes part of the command.