1
OS Prep
2
Installation
3
Post-Install
4
Validation

$ sql-server-install

Step-by-step guide for installing MS SQL Server on Windows Server. Tested and optimized according to best practices.

SQL Server 2025 · GA: Nov 18, 2025 · Latest Version · Compatibility 170
1
Minimum Hardware and OS Requirements
Ensure the server meets the requirements before installing
Required
Before installing SQL Server, verify that the hardware and operating system meet the minimum requirements.
ComponentMinimumRecommended
RAM4 GB≥ 16 GB
CPU1.4 GHz × 1≥ 4 cores
OS Disk6 GBSSD
Data DiskSSD/NVMe
Log DiskSSD
TempDB DiskFastest SSD
OS2016+2022
SQL Server binaries and program files (C:\Program Files\Microsoft SQL Server\) on the C drive is perfectly OK. Data files (Data .mdf, Log .ldf, TempDB, Backup) must reside on separate drives — not C.
2
Windows Power Plan → High Performance
Balanced mode throttles CPU frequency and slows down SQL Server
Required
Windows defaults to the Balanced power plan, which lowers CPU frequency when idle. This causes noticeable latency. Change it to High Performance.
PowerShell · Admin
powercfg /setactive SCHEME_MIN
powercfg /getactivescheme
For virtual machines (VMware, Hyper-V), also check the host server power plan. Make sure VM power management does not block the High Performance plan.
3
Required Windows Features
.NET Framework, WMI, Remote Registry
Required
SQL Server requires certain Windows features. Install them before running the SQL Server setup.
PowerShell · Admin
Install-WindowsFeature Net-Framework-Core
Install-WindowsFeature Net-Framework-45-Core
4
Create Dedicated Service Accounts
Separate accounts for SQL Server Engine, Agent, and SSRS
Required
Use separate low-privilege accounts for each SQL Server service. Never use Local System, Local Admin, or Domain Admin accounts!
🚫
Using the SYSTEM account is a critical security risk. The Health Check will flag this as "critical". Always create dedicated service accounts.
  • svc-sqlengine — SQL Server Database Engine service. Minimum privileges, logon as service.
  • svc-sqlagent — SQL Server Agent. Separate account, rights to run Agent jobs.
  • svc-ssrs — Reporting Services (only if SSRS is installed).
💡
In a production domain environment, use gMSA (Group Managed Service Account) — passwords rotate automatically and require no manual management.
5
Firewall Rules
SQL Server port 1433, Browser 1434/UDP
Required
Open the necessary ports in Windows Firewall. Always use specific source IP ranges in your rules, never "any".
PowerShell · Admin
New-NetFirewallRule -DisplayName "SQL Server TCP 1433" -Direction Inbound -Protocol TCP -LocalPort 1433 -Action Allow
New-NetFirewallRule -DisplayName "SQL Browser UDP 1434" -Direction Inbound -Protocol UDP -LocalPort 1434 -Action Allow
New-NetFirewallRule -DisplayName "SQL DAC TCP 1434" -Direction Inbound -Protocol TCP -LocalPort 1434 -Action Allow
1
Choose SQL Server Edition
Enterprise, Standard, Developer, Express
Required
Select the right edition for your needs. Always develop and test using the Developer edition (free, all Enterprise features).
Enterprise
All features. Unlimited RAM/CPU. Always On AG.
Production
Standard
128 GB RAM. 24 cores.
Production
Developer
Free. Enterprise features. Not for production.
Dev/Test
Express
10 GB DB limit, 1 GB RAM.
Avoid
2
Collation Selection
Critically important — changing later is very difficult
RequiredIrreversible
Collation determines how SQL Server sorts and compares text. Changing the server-level collation after installation is highly complex (requires reinstallation).
🚫
Do not use SQL_Latin1_General_CP1_CI_AS — it is an outdated legacy collation. Always use a Unicode-based collation.
Collation
Finnish_Swedish_CI_AS✓ (ET)
Latin1_General_CI_AS✓ (Intl)
SQL_Latin1_General_CP1_CI_AS✗ Legacy
3
Features to Install
Install only what you actually need
Recommended
Reduce the attack surface — install only the required components. Additional features can always be added later.
  • Database Engine Services — Required. The core of SQL Server.
  • SQL Server Agent — Required. Automated jobs, backups, maintenance.
  • Full-Text Search — Recommended if your application uses text search.
  • Reporting Services (SSRS) — Only if needed. Install on a separate server if possible.
Machine Learning Services, PolyBase, R, Python — Do not install unless required. They add to the attack surface and consume resources.
4
Data Directory Locations
Data, Log, TempDB, and Backups on separate drives
Required
Set all directories correctly during the installation wizard. Moving them later is tedious and requires downtime.
TempDB file count: In the setup wizard, set the number of TempDB files = number of logical processors, up to a max of 8. Example: 8 logical processors → 8 TempDB data files, all equally sized.
5
Authentication Mode and SA Account
Windows Auth vs Mixed Mode, Securing SA
Required
If possible, use only Windows Authentication. If the application requires SQL logins, select Mixed Mode — but secure the SA account immediately after installation.
After installation, rename the SA account and disable it (if not used). Set a strong password for SA even if it is disabled.
T-SQL
ALTER LOGIN [sa] WITH NAME = [sql_sa_disabled];
ALTER LOGIN [sql_sa_disabled] DISABLE;
CREATE LOGIN [AdminUser] WITH PASSWORD = 'StrongPassword!';
ALTER SERVER ROLE [sysadmin] ADD MEMBER [AdminUser];
1
Install the latest Cumulative Update (CU)
Immediately after installation — before first use
Required
SQL Server RTM (Release to Manufacturing) versions contain known bugs. Always install the latest CU before going into production.
🔗
Find the latest CU versions at: sqlserverbuilds.blogspot.com — The Health Check tool will automatically verify if you are up to date.
2
Instant File Initialization (IFI)
Dramatically speeds up data file creation and autogrowth
Recommended
IFI allows SQL Server to initialize data files without zeroing out disk space. Speeds up file creation and autogrowth 10-100x. Does not affect log files.
After enabling IFI, run the Health Check tool — it will automatically check the IFI status and let you know if the setting is applied.
3
Enable Remote DAC (Dedicated Admin Connection)
Emergency access to an overloaded server
Recommended
DAC allows a connection to the server when SQL Server is otherwise overloaded and rejecting normal connections. Without it, you may be locked out of the server during an emergency.
4
Configure Database Mail
Required for alerts and Agent job notifications
Recommended
Database Mail allows SQL Agent to send emails regarding failed jobs, alerts, and warnings. Without it, you will not receive automated notifications.
5
Critical SQL Agent Alerts
Severity 19-25 and data corruption alerts
Required
Create alerts for critical SQL Server errors. Without them, you won't be notified about data corruption or critical hardware faults.
1
Run the Health Check Tool
Automatically checks 34+ parameters
Required
After applying all settings, run the dba.ee Health Check tool — it automatically verifies 34+ parameters and provides recommendations.
After installation, the Health Check should show: 0 critical, max 2-3 warnings (e.g., MSDB history is empty, some config options not yet set).
2
Apply Core Configuration
Max Memory, MAXDOP, CTP, and other critical settings
Required
After installation, many critical settings remain at defaults which are not suitable for production. Proceed to the configuration guide.
3
Configure Backup Plan
FULL, DIFF, LOG backups as Agent jobs
Required
Before first use, you must configure backups. SQL Server does not back up anything automatically by default.
💡
Use the Ola Hallengren maintenance solution — the industry standard for SQL Server backup and maintenance jobs. Free and well-tested.
Installation Complete!
Next steps: configure SQL Server for optimal performance
🔍 Open SQL Server Health Check →