Deploying roles to VHDs

This video will look at how you can add roles and features to a VHD file. A VHD file is commonly used when a server is virtualized using a product like Hyper-V. This feature allows you to add a role or feature to the VHD file when the server is not running.

Download the PDF handout

What we will do in this video?
In this video, there is a Hyper-V server which is running a virtual server using Hyper-V. The server’s virtual hard disk is stored in a VHD file which is stored on the Hyper-V server. Since a lot of administration on a network is performed from an administrator’s workstation, in this video the role will be added using an administrator workstation. In order for this to occur, the folder containing the VHD file on the Hyper-V server needs to be shared. Also there needs to be some firewall changes made in order for the workstation to be able to access the Hyper-V file.

In this demonstration, the virtual machine is currently not running. The procedure will not work if the operating system is running. However, if the operating system is running, you can add roles and features from remote using Server Manager.
1. In order to make changes to the VHD file, the workstation needs to be able to access the file by sharing the folder that has the file in it. This will be done using computer management, however this cannot be done until some firewall changes are made.
2. To make changes to the firewall from remote, add the server into server manager, right click the server and then select the option PowerShell. This will launch PowerShell which will be running on the remote server.
3. To make the changes to the firewall to allow a share to be created from remote, the following two commands need to be run from PowerShell.
Netsh advfirewall firewall set rule group=”Windows Management Instrumentation (WMI)” new enable=yes
Netsh advfirewall firewall set rule group=”Remote Event Log Management” new enable=yes
4. Now that the firewall rules have been changed, if the server is right clicked on in Server Manager, it will now be possible to run Computer Management.
5. To create a new shared folder, expand down to Shares under Shared folder, right click it and select the option “New Share”.
6. To create the share it is just a matter of completing the wizard. This involves browsing to the location of the folder containing the VHD file and entering in a share name when asked.
7. The permissions need to be configured as “change” for the administrator performing the changes and also the system user. What happens is the administrator’s user account performing the administration will launch some commands which will mount the VHD on the local server. Once mounted, additional commands will be sent using the system user. For this reason, the system user also needs access. If the system user does not have access, the process will fail.
8. Once the share has been setup, roles and features can be added by selecting “Add Roles and Features” under manage.
9. The process is much the same as installing a role or feature on the local server. Select the default option “Role-based or feature-based installation” and then on the next screen select the option “Select a virtual hard disk”.
10. Server Manager will ask you which server the VHD file will be mounted to. You should choose the server that is holding the VHD file whenever possible. If you choose a server that is not holding the VHD file, this means more data will need to be transferred over the network slowing down the overall process.
11. At the bottom of the select destination server, you also need to enter the full filename and path of the VHD file on the network.
12. Server manager will attempt to connect to the VHD file and determine which roles and features are installed. Once it does this, the wizard will run the same way it would if the administrator was installing the role or feature on the local server.
13. To access Hyper-V running on another system, run Hyper-V Manager from the start menu.
14. Hyper-V Manager is not part of Remote Server Administration Tools (RSAT). To add it to the system, open the control panel and select Programs and then select “Turn Windows Features on or off”. In the list tick the option “Hyper-V Management Tools” under Hyper-V.

“Installing and Configuring Windows Server 2012 Exam Ref 70-410” pg 34 – 35

Theme developed by TouchSize - Premium WordPress Themes and Websites