🏠 Home / Hub

🪟 Windows Server Lesson 08 — Full Server Setup Project

← Windows Server Menu | 🏠 Hub

Project Goal

Small office lab တစ်ခုအနေနဲ့ Windows Server ကို Domain Controller, Active Directory, DNS, DHCP, File Server, Group Policy, IIS Web Server, Backup နဲ့ Security baseline အထိ တည်ဆောက်မယ်။

Practice အတွက် VirtualBox/VMware/Hyper-V ထဲမှာ Server VM 1 လုံးနဲ့ Windows Client VM 1 လုံးရှိရင် လုံလောက်ပါတယ်။

1. Lab Design

ItemValuePurpose
Domainlab.localInternal AD domain
Server NameSRV-DC01Domain Controller
Server IP192.168.10.10/24Static IP
Gateway192.168.10.1Router
DNS192.168.10.10AD-integrated DNS
DHCP Scope192.168.10.100-200Client IP pool

2. Initial Server Setup

Rename server to SRV-DC01.
Set static IP: 192.168.10.10, gateway 192.168.10.1, DNS 127.0.0.1 initially.
Install latest Windows Updates.
Rename-Computer -NewName "SRV-DC01" -Restart

New-NetIPAddress -InterfaceAlias "Ethernet" `
  -IPAddress 192.168.10.10 `
  -PrefixLength 24 `
  -DefaultGateway 192.168.10.1

Set-DnsClientServerAddress -InterfaceAlias "Ethernet" `
  -ServerAddresses 127.0.0.1

3. Install AD DS + DNS

Install-WindowsFeature AD-Domain-Services,DNS -IncludeManagementTools

Install-ADDSForest `
  -DomainName "lab.local" `
  -DomainNetbiosName "LAB" `
  -InstallDns `
  -Force
Reboot ပြီးနောက် login username က LAB\Administrator ဖြစ်သွားမယ်။

4. Create OUs, Users, Groups

New-ADOrganizationalUnit -Name "Users" -Path "DC=lab,DC=local"
New-ADOrganizationalUnit -Name "Computers" -Path "DC=lab,DC=local"
New-ADOrganizationalUnit -Name "Servers" -Path "DC=lab,DC=local"

New-ADGroup -Name "IT-Admins" -GroupScope Global -Path "OU=Users,DC=lab,DC=local"
New-ADGroup -Name "HR-Users" -GroupScope Global -Path "OU=Users,DC=lab,DC=local"

New-ADUser -Name "Aung Aung" -SamAccountName "aung" `
  -AccountPassword (Read-Host -AsSecureString "Password") `
  -Enabled $true -Path "OU=Users,DC=lab,DC=local"

5. Configure DHCP

Install-WindowsFeature DHCP -IncludeManagementTools
Add-DhcpServerInDC -DnsName "SRV-DC01.lab.local" -IPAddress 192.168.10.10

Add-DhcpServerv4Scope `
  -Name "LAB-LAN" `
  -StartRange 192.168.10.100 `
  -EndRange 192.168.10.200 `
  -SubnetMask 255.255.255.0

Set-DhcpServerv4OptionValue `
  -ScopeId 192.168.10.0 `
  -Router 192.168.10.1 `
  -DnsServer 192.168.10.10 `
  -DnsDomain "lab.local"

6. File Server + Shared Folders

New-Item -ItemType Directory -Path "D:\Shares\HR" -Force
New-Item -ItemType Directory -Path "D:\Shares\IT" -Force

New-SmbShare -Name "HR" -Path "D:\Shares\HR" -FullAccess "LAB\IT-Admins" -ChangeAccess "LAB\HR-Users"
New-SmbShare -Name "IT" -Path "D:\Shares\IT" -FullAccess "LAB\IT-Admins"

NTFS permission နဲ့ Share permission နှစ်ခုစလုံးကိုစစ်ပါ။ Least privilege principle သုံးပါ။

7. Group Policy Baseline

gpupdate /force
gpresult /r
rsop.msc

8. IIS Internal Website

Install-WindowsFeature Web-Server -IncludeManagementTools
New-Item -ItemType Directory -Path "C:\inetpub\labsite" -Force
Set-Content "C:\inetpub\labsite\index.html" "<h1>LAB Internal Site</h1>"

New-IISSite -Name "LabSite" `
  -BindingInformation "*:8080:" `
  -PhysicalPath "C:\inetpub\labsite"

DNS record တစ်ခုထည့်ပြီး intranet.lab.local နဲ့ access လုပ်နိုင်အောင် ပြင်နိုင်ပါတယ်။

9. Backup & Monitoring

Install-WindowsFeature Windows-Server-Backup
wbadmin start systemstatebackup -backuptarget:E: -quiet

Get-EventLog -LogName Security -Newest 20
Get-Service | Where-Object Status -ne Running

10. Final Validation Checklist

📌 Study Checklist