Yung Chou, Kevin Remde and Dan Stolts continue their TechNet Radio multi-part Windows 10 series and in part 2 they showcase free tools like the User State Migration Toolkit (USMT) that can easily migrate users and user data to Windows 10 from Windows XP, 7 and 8.
In the last few months, I have taken a few opportunities to talk about deploying an application as a service. This is a subject with many aspects in connecting the concepts of cloud computing, application deployment process and IT operations. I find it also encompasses great frequently run routines for automation with Azure PowerShell.
Here I share the material which I have integrated into IaaS workshops I have recently delivered.
- Part 1 is the user experience which is also supplemented with published videos. (Channel 9)
- Part 2 highlights the PowerShell scripts I wrote to deploy the sample application. (Channel 9)
This is the presentation I delivered in US MVP Open Days 2015. The key difference between on-premises deployment and cloud deployment of SharePoint or any application is the consideration of application fabric, particularly cloud service (or compute). Which is a focus on my delivery.
Windows Server 2012 R2 Hyper-V Role introduces a new capability, Hyper-V Replica, as a built-in replication mechanism at a virtual machine (VM) level. Hyper-V Replica can asynchronously replicate a selected VM running at a primary (or source) site to a designated replica (or target) site across LAN/WAN. The following schematic depicts this concept.
A replication process will replicate, i.e. create an identical VM in the Hyper-V Manager of a target replica server and subsequently the change tracking module of Hyper-V Replica will track and replicate the write-operations in the source VM every based on a set interval after the last successful replication regardless the associated vhd files are hosted in SMB shares, Cluster Shared Volumes (CSVs), SANs, or with directly attached storage devices.
Hyper-V Replica Requirements
Above both a primary site and a replica site are Windows Server 2012 R2 Hyper-V hosts where the former runs production or the so-called primary VMs, while the latter hosts replicated ones which are off and each is to be brought online, should a corresponding primary VM experience an outage. Hyper-V Replica requires neither shared storage, nor a specific storage hardware. Once an initial copy is replicated to a replica site, Hyper-V Replica will replicate only the changes of a configured primary VM, i.e. the deltas, asynchronously.
It goes without saying that assessing business needs and developing a plan on what to replicate and where is essential. In addition, both a primary site and a replica site (i.e. Hyper-V hosts run source and replica VMs, respectively) must enable Hyper-V Replica in the Hyper-V Settings of Hyper-V Manager. IP connectivity is assumed when applicable. Notice that Hyper-V Replica is a server capability and not applicable to client Hyper-V such as running Hyper-V in a Windows 8 client.
Establishing Hyper-V Replica Infrastructure
Once all the requirements are put in place, enable Hyper-V Replica on both a primary site (i.e. a Windows Server 2012 R2 Hyper-V host where a source VM runs) a target replica server, followed by configure an intended VM at a primary site for replication. The following is a sample process to establish Hyper-V Replica.
Step 1 – Enable Hyper-V Replica
Identify a Windows Server 2012 R2 Hyper-V host as a primary site where a target source VM runs. Enable Hyper-V Replica in the Hyper-V settings in Hyper-V Manager of the host. The following are Hyper-V Replica sample settings of a primary site. Repeat the step on a target replica site to enable Hyper-V Replica. In this article, DEVELOPMENT and VDI are both Windows Server 2012 R2 Hyper-V hosts where the former is a primary site while the latter is the replica site.
Step 2 – Configure Hyper-V Replica on Source VMs
Using the Hyper-V Manager of a primary site, enable Hyper-V Replica of a VM by right-clicking the VM and select the option, followed by walking through the wizard to establish a replication relationship with a target replica site. Below shows how to enable Hyper-V Replica of a VM, named A-Selected-VM, at the primary site, DEVELOPMENT. The replication settings are fairly straightforward and for a reader to get familiar with.
Step 3 – Carry Out an Initial Replication
While configuring Hyper-V Replica of a source VM in step 2, there are options to deliver an initial replica. If an initial replica is to be transmitted over the network, which can happen in real-time or according to a configured schedule. Optionally an initial copy can also be delivered out of band, i.e. with external media, while sending an initial copy on wire may overwhelm the network, not be reliable, take too long to do it or not be a preferred option due to the sensitivity of content. There are however additional considerations with out-of-band deliver of an initial replica.
Option to Send Initial Replica Out of Band
The following shows the option to send initial copy using external media while enabling Hyper-V Replica on a VM named A-Selected-VM.
An exported initial copy includes the associated VHD disk and an XML file capturing the configuration information as depicted below. This folder can then be delivered out of band to the target replica server and imported into the replica VM.
When delivering an initial copy with external media, a replica VM configuration remains automatically created at an intended replica site exactly the same with the user experience of sending a replica VM online. The difference is that a source VM (here the VM on the primary site, DEVELOPMENT) shows an initial replication in progress in replication health. The replica VM (here the VM on the replica site, VDI) has an option to import an initial replica in replica settings while the replication health information is presenting a warning as shown below:
The primary site
The replica site
After receiving the initial replica with external media, the replica VM can then import the disk a shown:
and upon successfully importing the disk, the following shows the replica VM now with additional replication options and updated replication health information.
Step 4 – Simulate a Failover from a Primary Site
This is done at an associated replica site. First verify and ensure the replication health on a target replica VM is normal. Then right-click the replica VM and select Test Failover in Replication settings as shown here:
Notice supposedly a failover should occur only when the primary VM experience outage. Nevertheless a simulated failover does not require shutting down a primary/source VM. It does create a VM instance after all at the replica site without altering the replica settings in place. A newly created VM instance resulted from a Test Failover should be deleted via the option, Stop Test Failover, via the replication UI where the Test Failover was originally initiated, as demonstrated below, to ensure all replication settings remain validated.
Step 5 – Do a Planned Failover from the Primary Site
In a maintenance event where a primary/source is expecting an outage, ensure the replication health is normal followed by conducting a Planned Failover from the primary site after shutting down the source VM as shown below.
Notice that successfully performing a Planned Failover with the presented settings will automatically establish a reverse replication relationship. To verify the failover has been correctly carried out, check the replication health of a replication pair of VMs on both the primary site and the replica site, prior and after a planned failover. The results need to be consistent across the board. The following examines a replication pair: A-Selected-VM on DEVELOPMENT at a primary site and the replica on VDI at the replica site. Prior to a planned failover from DEVELOPMENT, the replication health information of a source VM (left and at DEVELOPMENT server) and the replica VM (right and at VDI server) is as shown below.
After a successful planned failover event as demonstrated at the beginning of this step, the replication heath information becomes the following where the replication roles had been reversed and with a normal state. This signifies the planned failover was carried out successfully.
In the event that a source VM experiences an unexpected outage at a primary site, failing over a primary VM to a replica one in this scenario will not be able to automatically establish a reverse replication due to un-replicated changes have already lost along with the unexpected outage.
Step 6 – Finalize the Settings with Another Planned Failover
Conduct another Planned Failover event to confirm that a reverse replication works. In the presented scenario, the planned failover of a primary VM will be now shutting down in the primary site (i.e VDI at this time), followed by failing over back to the replica site (i.e. DEVELOPMENT at this time). And upon successful execution of the planned failover event, the resulted replication relationship should be DEVELOPMENT as a primary site with VDI as the replica site again. Which is the same state at the beginning of step 5. At this time, in a DR scenario, failing production site (in the above example DEVELOPMENT server) over to a DR site (here VDI server), and as needed failing over from the DR site (VDI server) back to the original production site (DEVELOPMENT server) are proven working bi-directionally.
Step 7 – Incorporate Hyper-V Replica into Existing SOPs
Incorporate Hyper-V Replica configurations and maintenance into applicable IT standard operating procedures and start monitoring and maintaining the health of Hyper-V Replica resources.
Hyper-V Extended Replication
In Windows Server 2012 R2, we can now further replicate a replica VM form a replica site to an extended replica site, similar to a backup’s backup. The concept as illustrated below is quite simple.
The process is to first set up Hyper-V Replica from a primary site to a target replica site as described earlier in this article. Then at the replica site, simply configure Hyper-V Replica of a replica VM, as shown below. In this way, a source VM is replicated from a primary site to a replica site which then replicates the replica VM from the replica site to an extended replica site.
In a real-world setting, Hyper-V Extended Replication fits business needs. For instance, IT may want a replica site nearby for convenience and timely response in an event that monitored VMs are experience some localized outage within IT’s control, while the datacenter remains up and running. While in an outage causing an entire datacenter or geo-region to go down, an extended replication stored in a geo-distant location is pertinent.
Hyper-V Replica Broker
Importantly, if to employ a Hyper-v failover cluster as a replica site, one must use Failover Cluster Manager to perform all Hyper-V Replica configurations and management by first creating a Hyper-V Replica Broker role, as demonstrated below.
And here is a sample configuration:
Although the above uses Kerberos authentication, as far as Hyper-V Replica is concerned Windows Active Directory domain is not a requirement. Hyper-V Replica can also be implemented between workgroups and untrusted domains with a certificate-based authentication. Active Directory is however a requirement if involving a Hyper-v host which is part of a failover cluster as in the case of Hyper-V Replica Broker, and in such case all Hyper-V hosts of a failover cluster must be in the same Active Directory domain.
Business Continuity and Disaster Recovery (BCDR)
In a BC scenario and a planned failover event, for example a scheduled maintenance, of a primary VM, Hyper-V Replica will first copy any un-replicated changes to the replica VM, so that the event produces no loss of data. Once the planned failover is completed, the VM replica will then become the primary VM and carry the workload, while a reverse replication is automatically set. In a DR scenario, i.e. an unplanned outage of a primary VM, an operator will need to manually bring up the replicated VM with an expectation of some data loss, specifically data change since the last successfully replication based on the set replication interval.
The significance of Hyper-V Replica is not only the simplicity to understand and operate, but the readiness and affordability that comes with Windows Server 2012 R2. A DR solution for business in any sizes is now a reality with Windows Server 2012 R2 Hyper-V. For small and medium businesses, never at a time is a DR solution so feasible. IT pros can now configure, simulate and verify results in a productive and on-demand manner to formulate/prototype/pilot a DR solution at a VM level based on Windows Server 2012 R2 Hyper-V infrastructure. At the same time, in an enterprise setting, System Center family remains the strategic platform to maximize the benefits of Windows Server 2012 R2 and Hyper-V with a comprehensive system management solution including private cloud automation, process orchestration, services deployment and management at a datacenter level.
- Microsoft Virtual Academy and Server Training courses
- TechNet documentation – Deploy Hyper-V Replica
- Hyper-V Forums
- Capacity Planner for Hyper-V Replica
This presentation focuses on
- Microsoft Azure Infrastructure Services essentials
- Windows AD operability in Microsoft Azure
It is not about
- Windows AD design, implementation, or sys admin
- Microsoft Azure Active Directory
Call to Action
- Get it! Microsoft Azure 30-Day free trial
- Learn it! Microsoft Azure Infrastructure Services
- Check it! StaticVNet IP
- Find it! Azure pricing
- What-if!! Azure cost calculator
- Know it! Azure compliance
- Read it! Microsoft Azure SLA
Microsoft Azure RemoteApp is a solution which can be rapidly deployed for anywhere accessing remote resources with a variety of devices including Windows, Mac OS X, iOS, or Android. A user will install a Microsoft Remote Desktop client on an Internet-connected laptop, tablet, or phone and access RemoteApp applications running in Microsoft Azure, as if they were running on the user’s local computer. Notice that the stand URL to acquire Microsoft Azure RemoteApp client is https://www.remoteapp.windowsazure.com/. A Microsoft Azure subscription can create up to five RemoteApp services. Here’s an introduction.
IT also has an option to deploy RemoteApp as a stand-alone cloud service with Microsoft pre-built application collections or integrated with on-premises RDS infrastructure by bringing your own RDSH. The former is quite easy to set up and what this blog post presents. While the latter is a hybrid deployment scenario bridging on-premises RDS infrastructure with RemoteApp service in the cloud. In this case, IT will need to create a virtual network with defined address spaces and establish VPN connectivity between on-premises network and Azure RemoteApp.
IT now has an option to enable users to access corporate applications from anywhere and on a variety of devices by employing Azure RemoteApp without the need to deploy on-premises infrastructure. Both the application deployment and the user access of Azure RemoteApp are provided as services, while RemoteApp applications are centralized, protected, and running in Microsoft Azure which can publish, scale, or unpublish corporate applications on demand, as business needs change.
Overall, RemoteApp is a cost-effective solution for today’s dynamic business environment and a best-fit for serving fluctuating workforce or fast-changing business requirements. To assess RemoteApp, a Microsoft Azure subscription is required.
Microsoft Azure Trial Subscription
Freely available is a 30-day trial subscription at http://aka.ms/R2 which is a Microsoft landing page for downloading evaluation copies of Windows Server and System Center products. There is also an option to deploy Windows Server 2012 R2 Datacenter on Microsoft Azure. This is the option to start a registration process for acquiring a Microsoft Azure 30-Day trial subscription.
To ensure identity, credit card information is required. However, prior to the expiration a trial subscriber will get email notification to op-in or op-out. It is a direct way to test Microsoft Azure in production, live and free.
As of June 2014, RemoteApp is still in preview and one will need to sign up the preview feature to make the RemoteApp option available, once approved. After logging into Microsoft Azure Management Portal, a subscriber can access preview offerings by clicking the View My Bill option of the dropdown menu form the subscriber ID on the upper right corner. And notice in general the approval process of activating a preview feature is not immediate and some may take up a few days.
Once approved, the feature becomes available from the left navigation pane.
RemoteApp “Quick Create” Process
Quick Create is to deploy RemoteApp as a Stand-Alone cloud service. A RemoteApp deployment may take about 30 minutes for Azure to complete. The process followed is to publish applications, configure user access, and installing the client. It is very straightforward. When entering a user or group that you want to grant access to for this service. Use the “user@domain” or “domain/user” format. The user must be either a Microsoft Account, or a user or group account homed in the Default Directory of Azure Active Directory.
Start with REMOTEAPP workspace by clicking +NEW.
Quick Create Page
Here, just click Quick Create, specify a name, a region, and an application collection.
Once created, click the name or arrow to display the dashboard.
Quick Start Page
Like other Azure offerings, by default Quick Start page is first shown. A Quick Start page usually presents essential information and is a great resource page.
As described in the Quick Start page, publishing RemoteApp programs, configuring user access and installing the RemoteApp client is the process to configure a RemoteApp service.
Publishing RemoteApp Programs
Click either one to display the application collections.
Identify applications to be published and save the settings.
Configuring User Access
When entering user information, use the “user@domain” or “domain/user” format. The user must be either a Microsoft Account, or a user or group account homed in the Default Directory of Azure Active Directory.
Installing RemoteApp Client
Pick an intended client. Here, I picked Windows x64 client.
Starts an installation of the RemoteApp client.
The RemoteApp tile is placed in APPS page, once the client installed.
Start configuring the user information.
Once authenticated, the published applications are displayed.
This is the About information.
Running RemoteApp Program
Here’s Office Word coming up.
Can save a file to OneDrive or locations visible to local File Explorer.