[20740C] Module 02: Configuring Local Storage
1. Lab: Configuring local storage
Scenario:
Your manager has asked you to add disk space to a file server that is running on a
virtual machine. This virtual machine will potentially grow significantly in size
in the upcoming months and you might need flexibility in your storage options. Your
manager has asked you to optimize the cluster and sector size for virtual machines
usage to accommodate large file sizes for storage on virtual machines. You need to
assess the best options for storage and ease of expansion for potential future use.
Next Exercise
2. Exercise 1: Creating and managing volumes
Task 1: Create a hard disk volume and format for ReFS
Switch to LON-SVR1.
Right-click Start, and then click Windows PowerShell (Admin).
To list all the available disks that have yet to be initialized, at the Windows
PowerShell command prompt, type the following command, and then press Enter:
Get-Disk | Where-Object PartitionStyle -Eq "RAW"
To initialize disk 2, at the Windows PowerShell command prompt, type the following
command, and then press Enter:
Initialize-disk 2
To review the partition table type, at the Windows PowerShell command prompt, type
the following command, and then press Enter:
Get-disk
To create a Resilient File System (ReFS) volume by using all available space on
disk 1, at the Windows PowerShell command prompt, type the following command, and
then press Enter:
New-Partition -DiskNumber 2 -UseMaximumSize -AssignDriveLetter | Format-Volume
-NewFileSystemLabel "Simple" -FileSystem ReFS
On the taskbar, click File Explorer.
If you receive the prompt, Do you want to format it?, click Cancel.
On the taskbar, click File Explorer.
Question : What drive letter has been assigned to the newly created volume?
Answer : Answers might vary, but it is assumed to be drive F.
Previous ExerciseNext Exercise
3. Exercise 1: Creating and managing volumes
Task 2: Create a mirrored volume
Right-click Start, and then click Disk Management.
In the lower half of the display, scroll down and right-click Disk 3, and then
click Online.
Repeat for Disk 4.
Close and reopen Disk Management.
In the Initialize Disk dialog box, click OK to initialize disks 3 and 4.
On Disk 3, right-click Unallocated, and then click New Mirrored Volume.
In the New Mirrored Volume Wizard, click Next.
On the Select Disks page, in the available list, click Disk 4, and then click Add
>.
In the Select the amount of space in MB box, accept the default value, and then
click Next.
On the Assign Drive Letter or Path page, in the Assign the following drive letter
box, click M, and then click Next.
On the Format Volume page, in the Volume label text box, type MIRROR.
Select the Perform a quick format check box, and then click Next.
Click Finish to create your mirrored volume.
In the Disk Management dialog box, click Yes to convert both disks to dynamic
disks.
Previous ExerciseNext Exercise
4. Exercise 2: Resizing volumes
Task 1: Create a simple volume and resize it
Switch to Windows PowerShell (Admin).
At the Windows PowerShell command prompt, type the following command, and then
press Enter:
Initialize-disk 5
At the Windows PowerShell command prompt, type the following command, and then
press Enter:
Diskpart
At the command prompt, type the following command, and then press Enter:
List disk
At the command prompt, type the following command, and then press Enter:
Select disk 5
At the command prompt, type the following command, and then press Enter:
Convert dynamic
At the command prompt, type the following command, and then press Enter:
Create volume simple size=10000 disk=5
At the command prompt, type the following command, and then press Enter:
Assign letter=z
At the command prompt, type the following command, and then press Enter:
Format
Switch to Disk Management. Verify the presence of an NTFS volume on Disk 5 of size
approximately 10 gigabytes (GB).
At the Windows PowerShell command prompt, type the following command, and then
press Enter:
Extend size 10000
Switch to Disk Management.
Verify the presence of an NTFS volume on Disk 5 of size approximately 20 GB.
Previous ExerciseNext Exercise
5. Exercise 2: Resizing volumes
Task 2: Shrink a volume
At the Windows PowerShell command prompt, type the following command, and then
press Enter:
Shrink desired=15000
Switch to Disk Management.
Verify the presence of an NTFS volume on Disk 5 of size approximately 5 GB.
Close the Windows PowerShell (Admin) window.
Previous ExerciseNext Exercise
6. Exercise 2: Resizing volumes
Task 3: Prepare for the next exercise
On the host computer, start Microsoft Hyper-V Manager.
In the Virtual Machines list, right-click 20740C-LON-DC1, and then click Revert.
In the Revert Virtual Machine dialog box, click Revert.
Repeat steps 2 and 3 for 20740C-LON-SVR1.
Restart your computer and select 20740C-LON-HOST1 when prompted.
Sign in as Administrator with the password [Link].
Previous ExerciseNext Exercise
7. Exercise 3: Managing virtual hard disks
Task 1: Install the Hyper-V module
On LON-SVR1, click Start, and then click Server Manager.
In Server Manager, click Add roles and features.
In the Add Roles and Features Wizard, on the Before you begin page, click Next.
On the Select installation type page, click Next.
On the Select destination server page, click Next.
On the Select server roles page, select the Hyper-V check box, click Add Features,
and then click Next.
On the Select features page, click Next.
On the Hyper-V page, click Next.
On the Create Virtual Switches page, click Next.
On the Virtual Machine Migration page, click Next.
On the Default Stores page, click Next.
On the Confirm installation selections page, select Restart the destination server
automatically if required, click Yes, and then click Install.
Note: Your computer might restart several times following installation of the
Hyper-V components.
Sign in as Administrator with the password [Link].
Previous ExerciseNext Exercise
8. Exercise 3: Managing virtual hard disks
Task 2: Create a virtual hard disk
On LON-SVR1, right-click Start, and then click Windows PowerShell (Admin).
At the Windows PowerShell command prompt, type the following command, and then
press Enter:
New-VHD -Path c:\[Link] -Dynamic -SizeBytes 10Gb | Mount-VHD -Passthru |
Initialize-Disk -Passthru |New-Partition -AssignDriveLetter -UseMaximumSize |
Format-Volume -FileSystem NTFS -Confirm:$false -Force
Note: If you receive a Microsoft Windows pop-up dialog box prompting you to format
the disk, close it and continue.
Previous ExerciseNext Exercise
9. Exercise 3: Managing virtual hard disks
Task 3: Reconfigure the virtual hard disk
Note- These steps are a duplicate of the high-level steps.
To dismount the virtual hard disk, at the Windows PowerShell command prompt, type
the following command, and then press Enter:
Dismount-vhd C:\[Link]
To check the properties of the virtual hard disk, at the Windows PowerShell command
prompt, type the following command, and then press Enter:
Get-vhd C:\[Link]
Question :What is the physical sector size?
Answer : Answers will vary, but it is likely to be 512.
To convert to a .vhdx file, at the Windows PowerShell command prompt, type the
following command, and then press Enter:
Convert-VHD -Path C:\[Link] -DestinationPath c:\[Link]
To change the sector size, at the Windows PowerShell command prompt, type the
following command, and then press Enter:
Set-VHD -Path c:\[Link] -PhysicalSectorSizeBytes 4096
To check the properties of the .vhdx file, at the Windows PowerShell command
prompt, type the following command, and then press Enter:
Get-vhd C:\[Link]
Question : What is the physical sector size?
Answer : Answers will vary, but it is likely to be 4096.
To optimize the .vhdx file, at the Windows PowerShell command prompt, type the
following command, and then press Enter:
Optimize-VHD -Path c:\[Link] -Mode Full
Previous ExerciseNext Exercise
10. Exercise 3: Managing virtual hard disks
Task 4: Prepare for the next module
Restart your computer, and when prompted, choose Windows Server 2016.
Previous Exercise