esSJae's Virtualization Blog

Virtualization and other IT topics

Hyper-V Server/Powershell Info


Steps to add a new hard drive to Hyper-V Server via command line:

  1. Start diskpart:              C:\>diskpart
  2. Find the disk:                DISKPART> list disk
  3. Select the disk:             DISKPART>select disk 1   
  4. Put disk online:            DISKPART>online disk
  5. Reselect the disk:        DISKPART>select disk 1
  6. Create the partitionDISKPART>create partition primary
  7. Find and select the new volume:
    1. DISKPART> list volume
    2. DISKPART>select volume 2
  8. Format the drive and assign a drive letter: 
    1. DISKPART> select volume 2
    2. DISKPART> format fs=ntfs label=”VMs” quick  
    3. DISKPART> assign letter=v
    4. DISKPART> exit

 

Clear attributes: ATTRIBUTES VOLUME CLEAR READONLY

 

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.