migrate a 3-tier web application to a private cloud · reference architecture intel® cloud uilders...

21
REFERENCE ARCHITECTURE Intel® Cloud Builders Hewlett Packard Enterprise Executive Summary Cloud is critical to delivering the agility and speed that business demands. IDC states, “effective cloud computing environments empower end users, facilitate business agility, optimize cost and resource consumption, control business risk, and enforce regulatory compliance via the use of automation, analytics, and stan- dards.” 1 With up to 90 percent of IT budgets spent on maintaining existing systems, 2 businesses are looking for new ways to accelerate service delivery, optimize efficiencies, and reduce costs. 1 Hybrid Cloud Management, IDC MaturityScape, January 2015 2 Updates to HP Helion (now HPE Helion) Portfolio Help Customers Unlock Value of a Hybrid Infrastructure, HP (now Hewlett Packard Enterprise) press release, June 2015 3 Voice of the Enterprise Cloud Computing Customer Insight Survey, 451 Research, Q4 2014 4 The Key Benefits of Deploying Private Clouds, Aberdeen Group, July 2014 To meet these demands, it’s estimated that more than half of all enterprise application workloads will be deployed in private or hybrid clouds by the end of 2016. 3 By moving workloads to the cloud, infrastructure and services can be delivered faster, and costs can be reduced by up to 40 percent. 4 And moving to a private cloud reduces pressure on IT resources and budgets, allowing reinvestment in modernizing applications that drive business growth. With an unmatched and integrated portfolio of servers, storage, network- ing, software, and services, Hewlett Packard Enterprise can help enterprises build a fully integrated and optimized private cloud that’s right for their busi- ness—on-premise and under their control. With reduced risk and faster time to market, enterprises can migrate applications with increased confidence to empower IT, business users, and customers to drive better business outcomes. This reference architecture provides a recommended approach for the migra- tion of an application workload from a traditional 3-tier deployment model to a private cloud-based architecture. A private cloud empowers employees to accelerate time-to-value quickly and securely by virtualizing infrastructure and offering infrastructure provisioning as well as application deployment as a service. VMware® vSphere ESXi is used to virtualize the physical resources and aggregate them into logical pools for allocation of the application workloads. HPE Cloud Service Automation (CSA) Migrate a 3-Tier Web Application to a Private Cloud Intel® Cloud Builders HPE Application Migration to Cloud

Upload: donhu

Post on 24-May-2018

217 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

reference architectureIntel® Cloud BuildersHewlett Packard Enterprise

Executive Summary

Cloud is critical to delivering the agility and speed that business demands. IDC states, “effective cloud computing environments empower end users, facilitate business agility, optimize cost and resource consumption, control business risk, and enforce regulatory compliance via the use of automation, analytics, and stan-dards.”1 With up to 90 percent of IT budgets spent on maintaining existing systems,2 businesses are looking for new ways to accelerate service delivery, optimize efficiencies, and reduce costs.

1 Hybrid Cloud Management, IDC MaturityScape, January 20152 Updates to HP Helion (now HPE Helion) Portfolio Help Customers Unlock Value of a Hybrid Infrastructure, HP (now Hewlett Packard

Enterprise) press release, June 20153 Voice of the Enterprise Cloud Computing Customer Insight Survey, 451 Research, Q4 20144 The Key Benefits of Deploying Private Clouds, Aberdeen Group, July 2014

To meet these demands, it’s estimated that more than half of all enterprise application workloads will be deployed in private or hybrid clouds by the end of 2016.3 By moving workloads to the cloud, infrastructure and services can be delivered faster, and costs can be reduced by up to 40 percent.4 And moving to a private cloud reduces pressure on IT resources and budgets, allowing reinvestment in modernizing applications that drive business growth.

With an unmatched and integrated portfolio of servers, storage, network-ing, software, and services, Hewlett Packard Enterprise can help enterprises build a fully integrated and optimized private cloud that’s right for their busi-ness—on-premise and under their control. With reduced risk and faster

time to market, enterprises can migrate applications with increased confidence to empower IT, business users, and customers to drive better business outcomes.

This reference architecture provides a recommended approach for the migra-tion of an application workload from a traditional 3-tier deployment model to a private cloud-based architecture. A private cloud empowers employees to accelerate time-to-value quickly and securely by virtualizing infrastructure and offering infrastructure provisioning as well as application deployment as a service. VMware® vSphere ESXi is used to virtualize the physical resources and aggregate them into logical pools for allocation of the application workloads. HPE Cloud Service Automation (CSA)

Migrate a 3-Tier Web Application to a Private CloudIntel® Cloud Builders HPE Application Migration to Cloud

Page 2: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Table of Contents

Executive Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

Target Audience & Document Purpose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

Solution Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

Solution Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

Key Assumptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5

Example Of Application Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

Solution Approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7

Solution Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

Hardware . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

Software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

Services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9

Solution Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10

Add VMware vCenter Resource Provider . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

DayTrader Service Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12

Attach HPE OO Flows to Lifecycle Stages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

Integrate HPE OO Flows & VMware vCenter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

Invoke Custom Scripts Via HPE OO Flows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

Subscribing & Accessing the Application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

Migration Recommendations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Apache Web Server Migration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Geronimo Application Server Migration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Database Server Migration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17

Automating Migrations Using HPE CSA & HPE OO . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Appendix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Software Inventory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Solution Sizing & Testing Methodology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19

Sizing Recommendations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

Database Migration Using MySQL Workbench . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

Acronyms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23

5 Based on HP SmartCache (now HPE SmartCache) performance testing done with equivalent controller in a controlled environment, May 2014

2Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

manages the entire service provisioning process, with an easy-to-use self-service portal delivering a seamless experience for IT users.

As the compute engine for the refer-ence architecture, HPE ProLiant Gen9 servers boost workload performance by up to four times.5 The performance, availability, and scalability of HPE ProLiant and HPE 3PAR StoreServ delivers the power and capacity needed to ensure migrated applications meet service-level agreements to drive increased productivity and business growth. And to protect and ensure on-time data availability, HPE CSA enables reliable and compliant services to meet corporate and regulatory standards.

Given that migrating applications to a private cloud is a complex process, HPE Workload Portability Services eases the journey to the cloud and ensures the applications migrated meets business objectives by leveraging the expertise as well as cloud best practices of HPE Technology Services. HPE Technol-ogy Refresh for Computing from HPE Financial Services enables a flexible IT investment strategy that makes it easier to acquire, manage, and refresh technology solutions.

Target Audience & Document Purpose

This reference architecture is designed for IT directors, data center managers, and application owners who are evalu-ating options for migrating applications, data, and infrastructure to a private cloud environment. This document will help you understand the overall migra-tion steps and the Hewlett Packard En-terprise technologies that can be used to build a private cloud environment for a given application.

Page 3: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 3

Introduction

Cloud computing has gained accep-tance and mind share with enterprise data center managers. Increasingly, chief information officers and

IT professionals have decided to adopt public, private, or hybrid cloud tech-nologies to reduce costs, improve operational efficiency, and increase business agility for new application deployments.

Most large enterprises own existing data center and computing infrastruc-ture that operate outside of a cloud environment. These environments typically host databases, custom ap-plications, enterprise resource plan-ning systems, and order-processing systems that drive many of the critical workloads required for the business. Migrating such traditional applications to a cloud-based environment can be challenging and risky.

This reference architecture provides an example of how to migrate a traditional 3-tier Web application confidently to a private cloud-based environment using the Hewlett Packard Enterprise hard-ware, software, and services.

Solution Overview

In recent years, enterprises have realized the competitive advantage of building new applications and releasing them to market quicker. The cloud has enabled such enterprises to accelerate their application development cycles and reduce time-to-market.

A major feature of the cloud is that it provides a secure, automated, infra-structure services deployment capabil-ity. But, why should this matter to IT organizations? Largely, it’s because the cloud can help an enterprise respond to changing market dynamics more quickly, thus outpacing competitors to innovate faster.

Cloud solutions also tightly integrate with automation and orchestration tools. Orchestration tools enable de-ployment of advanced infrastructure and complex, multi-tiered, application, and platform services. These tools al-low the enterprises to focus on applica-tion development and testing, provid-ing greater value to the business versus spending time on infrastructure setup and management tasks.

Not all applications are cloud-ready. Few aspects have to be considered before deciding to migrate into a cloud environment. Some examples are listed as follows:

• Software licensing model: Software today is typically licensed in a way that either locks the product to a specific server or operating system instance or caps the license by the resources it uses (user count, CPU count, and more). This model will not fit well in a cloud environment since the resources are much more dynamic and flexible.

• Application interdependency: In a typical enterprise environment, ap-plications might be tightly intercon-nected with other applications within the organization, which are not cloud ready. Thus, migration of a chosen application might require migration of a larger set of dependent applica-tions.

• Hardware platform dependency: Some applications might be built to take advantage of certain hardware and operating system features that are not supported in a cloud environ-ment. Before such applications are migrated, it would be required to make them platform agnostic.

• Development tools and processes: For custom applications, it is im-portant to understand the pro-gramming languages, development tools, (source control systems, compilers, integrated development

environments, and test tools) and project-tracking tools (requirements management, defect tracking, and release management) required for the continued development of the application.

For most applications, it is necessary to conduct formal studies to determine which application workload could move to the cloud, which couldn’t without changes, and why. This activity involves analysis of each application based on the business, technical, and functional considerations and development of ap-plication groups that are good candi-dates for the private cloud.

Once you’ve identified the applica-tions to migrate, you need to decide on the migration strategy that would be applied for individual applications. Each application might have its own set of migration challenges such as effort required for application architecture and code changes, as well as enforcing security policies and data migration is-sues (for example, due to large dataset size).

Solution Description

Migrating applications to the cloud is a process (depicted in figure 1) consisting of four main phases briefly described as follows:

1. Application selection: Identify ap-plications that are good candidates for deploying in a private cloud environment after performing a thorough migration analysis.

2. Build private cloud infrastructure: Build the physical infrastructure (data center, server, storage, and network), virtualization layers, and supporting operational procedures (security, backup and recovery, management as well as monitoring, and more) for the environment.

3. Deployment automation and self-service portal: Setup the necessary software tools and develop the

Page 4: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

4Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Figure 2: Three-Tier Application Topology

Figure 1: Application Migration Cloud—Process Steps

automation procedures to deploy operating systems, application packages and configure the ap-plications.

4. Applications and data migra-tion: Migrate existing application configurations, packages, and data from the source to the target envi-ronment.

The solution example described in this document primarily addresses steps 3 and 4 shown in figure 1.

Key Assumptions

• It is assumed that the application has been selected and the physical infra-structure to deploy it has been built.

• The source environment is assumed to consist of physical servers or vir-tual machines (VMs) with dedicated operating system instances for each of the application tiers.

The intent of this paper is to show how to apply the migration process to the most typical 3-tier application architec-ture (as shown in figure 1).

A typical 3-tier application architecture involves a front-end Web server (or a load balancer), an application server that forms the middle tier, and a data-base server at the backend. Manually

Page 5: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

6 DayTrader application: geronimo.apache.org/GMOxDOC22/daytrader-a-more-complex-application.html 7 Image source: geronimo.apache.org/GMOxDOC22/daytrader-a-more-complex-application.html

5

provisioning servers, operating sys-tems, applications, and databases for each of the tiers can be time-consum-ing and error prone. It can be difficult to expand or add capacity to such an environment quickly, due to the lack of automated provisioning.

Example of Application Description

The solution described in this docu-ment uses an application called

DayTrader.6 DayTrader is a benchmark application built around the paradigm of an online stock trading system. The application enables users to log in, view their portfolio, lookup stock quotes, and buy or sell shares of stock.

This application was chosen because it is a good representative of a standard 3-tier application architecture com-monly used in enterprises. DayTrader

Figure 3: DayTrader Application Architecture7

is built on a core set of Java EE tech-nologies. It includes Java Servlets and Java Server Pages (JSPs) for the Web tier, Java database connectivity (JDBC), Java Message Service (JMS), Enterprise JavaBeans (EJB), and message-driven beans (MDBs) for the application tier and MySQL database for the data tier. A full architectural depiction of the ap-plication is provided in figure 3.

Page 6: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

6Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Figure 4: Private Cloud Deployment Architecture

Solution Approach

One of the key features of a cloud envi-ronment is the self-service capability it provides to end users and IT adminis-trators. In order to enable this capabil-ity, infrastructure provisioning, operat-ing system deployment, and activities for application software installation must be automated.

The solution described in this docu-ment will leverage the capabilities of HPE CSA and HPE Operations Orches-tration (OO) to implement the auto-mation and to enable the self-service capability.

Figure 4 depicts the automation flow that will be used for deploying the VMs required for the DayTrader application. A flow is a term used to describe HPE OO job definitions. HPE OO will ex-ecute flows to create VMs in a VMware vCenter environment. Once the VMs are deployed,

HPE OO will trigger different flows to execute custom scripts specifically de-veloped for the DayTrader application. These scripts perform the

task of installing and configuring the application software, such as Apache Web server, Geronimo application server, and MySQL DB server configura-tion within the respective VM.

After the VM, operating system, and application software are installed, the next step would be to migrate the application code, data, and configura-tions from the source environment to the newly created VM instances within the cloud environment. Details of the cloud deployment automation and application migration are provided in the Solution integration section of this document.

Solution Components

Building a private cloud infrastruc-ture involves setting up data center infrastructure (power, cooling, ca-bling, racks, and more), hardware devices (servers, storage, and network switches), and software (operating systems, hypervisors, and management software). Hewlett Packard Enterprise has a rich portfolio of products and services that can be used for building a private cloud infrastructure. A few of the applicable products and services a customer can choose to use while migrating from applications from a traditional IT infrastructure to a private cloud environment is described in the following section.

Hardware

HPE ProLiant DL380 Gen9 Server

HPE ProLiant DL380 Gen9 Server deliv-ers an optimal combination of perfor-mance, expandability, and availability to ensure cloud compute scalability along with state-of-the-art security capabilities.

HPE 3PAR StoreServ 8440 Storage

HPE 3PAR StoreServ 8440 offers unmatched performance, availability, and ease of management in an all-flash configuration for fast access to data.

HPE FlexFabric 5930 Switch

HPE FlexFabric 5930 Switch is a high-density, ultra-low-latency series of top-of-rack (ToR) switches designed to deliver optimal throughput and avail-ability for fast transfer of data within the cloud. For customers building a private cloud network infrastructure, Hewlett Packard Enterprise recom-mends a 10/40GbE spine and leaf (2-tier) network topology to support the changing network traffic patterns and bandwidth as well as buffering require-ments that are characteristic of cloud deployments. Additional information on these network design recommenda-tions can be found in the HPE FlexFab-ric Reference Architecture8 document.

While the reference architecture is based on these components, you can tailor the solution for your customer from our complete portfolio of serv-ers, storage, and switches to meet their specific needs.

Software

HPE Cloud Service Automation

The function of HPE CSA is to accel-erate the speed of deployment for application-based services across a hybrid cloud delivery environment. Tra-

8 HPE FlexFabric Reference Architecture h20195.www2.hp.com/V2/GetDocument.aspx?docname=4AA56480ENW&cc=us&lc=en

User

HPE CSA

HPE OO

ESXi

App server Web server

Application

DB server

ESXi

vCenter

Page 7: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 7

ditionally, IT staff was required to patch and update physical servers manually. Using HPE CSA, IT organizations can update thousands of servers automati-cally.

HPE CSA allows IT departments to move and manage applications among in-house (private) cloud systems, ex-ternal (public) clouds, and traditional IT systems. The HPE CSA software is also designed to deliver unified security, governance, and compliance across applications, as well as physical and virtual infrastructures. The software automates key IT processes so that there is one consistent approach to IT resource management.

HPE CSA works with HPE OO to provide IT lifecycle automation. HPE OO is an integrated set of software and services that helps to automate distributed systems and heterogeneous comput-ing environments. User organizations use HPE OO to link together separate applications to create a workflow across them.

HPE Operations Orchestration

HPE OO helps reduce operational costs and improve service quality by automating routine IT tasks, such as repetitive maintenance, change provi-sioning, and incident resolution. HPE OO provides author, deploy, and run capabilities.

Author

HPE OO Studio is the flow authoring and deployment tool in HPE OO. The powerful built in debugger allows test-ing of flows on multiple environments and accelerates content development. It also enables validation of flows for reliable execution. Many IT organiza-tions create scripts to perform standard tasks. However, they largely use manual processes for task execution and there are limits to this approach.

Scripts for complex processes that touch multiple systems and applica-tions are difficult to create. Scripts are also hard to maintain, share, or reuse, they cannot be validated for reliability prior to execution and are not audit-able. HPE OO addresses the limitations of scripting by reducing the administra-tive complexity of flow creation and authoring through an easy to use drag and wire Studio.

Deploy

Studio also allows users to deploy flows easily. Standard processes can be docu-mented and structured documentation can be generated, to support compli-ance requirements using Studio.

Run

HPE OO offers flexibility in flow execu-tion to reduce administrative time and increase agility. Flows may also be ex-ecuted sequentially or in parallel, which reduces the time to deploy a single change to a large group of devices, or to coordinate related changes to different device types (for example, server and storage devices). HPE OO provides the ability for real time inspection of step by step results and outcome of flows.

VMware vSphere ESXi

VMware vSphere is an industry-leading virtualization platform that empowers users to virtualize any application with confidence, redefines availability, and simplifies the virtual data center. The result is a highly available, resilient, on-demand infrastructure that is the ideal foundation of any cloud environment.

VMware vCenter Server

VMware vCenter Server provides a centralized and extensible platform for managing a virtual infrastructure. VMware vCenter Server manages VM-

ware vSphere environments, giving IT administrators simple and automated control over the virtual environment to deliver infrastructurewith confidence.

A detailed list of software used for the DayTrader application deployment is provided in the Software inventory sec-tion of the Appendix.

Services

For customers needing assistance with migrating their applications to a private cloud, HPE Technology Services offers various consulting services. Some of the relevant consulting services for such application migration projects are described as follows.

HPE Workload Portability Services

HPE Technology Services has a com-plete set of services to analyze the business, technical, and budgetary needs of application migration goals, along with a proven methodology in the form of HPE Workload Portability Services to deliver the right cloud to enable application transformation.

HPE Workload Portability Services has five phases:

• Phase 1: Discovery—understands the applications in your environment as a starting point.

• Phase 2: Suitability analysis—per-forms a formal study of the actual application workload and determines which workload should move to the cloud, which shouldn’t, and why. It also prioritizes the moves. The result is a manageable set of candidates destined to the cloud and prioritized for migration.

• Phase 3: Mapping—helps identify the right type of cloud for each workload based on the business, technical, and functional needs.

Page 8: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

8Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

• Phase 4: Workload migration—is the act of actual migration.

• Phase 5: Cloud enablement—vali-dates the connections, service levels, security, and performance consider-ations of the newly formed cloud in order to maintain and enhance the level of service supported before the migrations.

Throughout all these phases, HPE Tech-nology Services analyzes the business, technical, and budgetary needs and matches the migration to meet those needs. The services are separable and are often done iteratively, starting with a subset of workloads and migrating until all the workloads that can and should migrate are running in the right type of cloud.

HPE Flexible Capacity

HPE Flexible Capacity is unique in the marketplace in delivering the IT infra-structure and the personalized support customers need on premise, to flexibly provision capacity on demand and thus deliver quickly against the dynamic

Discovery Suitability analysis

1 2

Mapping to cloud

3

Workload migration

4Cloud enablement

5

Figure 5: HPE Workload Portability Services

IT needs of their businesses, all with the scalability and pay-as-you-grow flexibility of the public cloud. Unlike a public cloud service, Flexible Capacity delivers capacity on-premise, enabling customers to maintain control of IT for reasons of privacy, compliance, latency, and security.

HPE Datacenter Care

With the HPE Datacenter Care solution, customers can choose the right level of hardware and software support for each device in their data center, includ-ing multivendor, with Reactive Support Services. The assigned account team provides a single point of accountabili-ty, is familiar with the environment, and offers Enhanced Call Handling regard-less of the level of reactive support. With Proactive Services, customers get to select the proactive deliverables they need, when and where they need them. They can also choose from a wide range of “building blocks” of services to meet their specific requirements.

HPE Technology Refresh for Computing

HPE Technology Refresh for Computing allows payments of new infrastructure to be deferred for up to 90 days, and—if there is a need to depreciate equip-ment before migrating—Hewlett Pack-ard Enterprise can purchase existing servers and convert them to a monthly payment for a transitional period to move expenses from capital budget to operating budget. Monthly payment options also offer significant savings vs. a cash purchase, and Hewlett Packard Enterprise can bundle hardware, soft-ware, and services into a single pay-ment to simplify accounting.

With the HPE Technology Refresh program, customers set the term that fits their IT lifecycle and customize it as needed to either extend it or upgrade sooner. Value-added services such as pack and ship or compliant data removal services can help customer’s staff be more productive and focus on higher priorities. And customers can be rest assured knowing that industry best practices are being employed to securely remove data and recycle equipment.

Solution Integration

The solution includes integration of various hardware, operating system, and application software components. Details of setting up the hardware (such as server, storage, and networking com-ponents) for the cloud infrastructure are not in the scope of this document. It is assumed that the infrastructure is built prior to performing the steps listed later in the document.

At a high level, various tasks involved in deploying the DayTrader application in a private cloud environment are listed as follows:

• Automating VM deployment

• Installation of relevant components

Page 9: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 9

Figure 6: Resource Provider Offerings

on each node such as application server, database server, and Web server applications

• Node configuration after VM deploy-ment through gathering information and updating corresponding configu-ration files

• Offering three different service con-figurations, such as small, medium, and large to cater to different end-user needs.

Each of the steps required to imple-ment the deployment automation and

to enable self-service capability with HPE CSA is described in detail in the following section.

Add VMware vCenter Resource Provider

A resource provider is a management platform that offers centralized control over the infrastructure and resources used in a cloud-computing environ-ment. A provider corresponds to the specific instance of an application that HPE CSA can integrate with to help instantiate service designs. In this refer-

ence architecture, HPE CSA uses VM-ware vCenter as the resource provider. HPE CSA will need to register VMware vCenter as a resource provider before it can start deploying VMs on the VM-ware vSphere ESXi hosts managed by VMware vCenter.

To facilitate the process of creating new VMs quickly, we created VM templates for each of the DayTrader application tiers. All the software necessary for each of the respective tiers was de-ployed into these VM templates.

Figure 7: VM Templates in VMware vCenter

Page 10: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

10Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

DayTrader Service Design

Service designs are the recipes for automating the cloud comprise reus-able service components. Service components and their relationships in a service design define the framework for creating the service.

Figure 8: Daytrader Small Service Design

For the DayTrader application, we will be creating three service offerings based on the number of user requests it can support, namely small, medium, and large. Service offerings encapsulate all the information and consumers need to select the most appropriate services. Each service offering references a ser-

vice design, which defines the service options and components of the service.

For DayTrader small configuration (fig-ure 8), we have created a server group that consists of three server compo-nents, namely the Web server, App server and DB server.

Page 11: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 11

For DayTrader medium (figure 9) and large (figure 10) configurations, multiple server groups were created, with each group catering to each tier of the application stack.

Figure 9: DayTrader Medium Service Design

Figure 10: DayTrader Large Service Design

1

1

1

1 2 3 4 5 1 2 3 1

2 3

DayTrader service composite

Infrastructure service

Web server group App server group DB server group

Web server 1 Web server 2 Web server 3 Web server 4 Load balancer 1 App server 1 App server 2 Load balancer 2 DB server

Page 12: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

12Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Attach HPE OO Flows to Lifecycle Stages

HPE CSA integrates with the HPE OO Engine to execute phases of a service request lifecycle. Specifically, the HPE CSA Lifecycle Designer tool processes this function.

The lifecycle phases (see figure 11) include:

• Initialized

• Reserved

• Deployed

HPE CSA Lifecycle Designer enables appropriate HPE OO flows to attach to various phases of a service lifecycle, and builds the environment required to deploy a workload.

Integrate HPE OO flows and VMware vCenter

When HPE CSA invokes an HPE OO flow, it will pass the service context

Figure 11: Service Request Phases

details (such as service request details, resource provider details,

and service design information) to the HPE OO flow. The HPE OO flows invoke VMware vCenter APIs against the re-source provider, spawning new VMs.

Several properties, such as the net-work and the compute characteristics are then passed using service design parameters. Once the HPE OO flow successfully creates VMs, HPE OO will return IP address, hostname, or other results to HPE CSA.

Invoke Custom Scripts via HPE OO Flows

Once the VM template is cloned, the VM needs to be customized according to the role it is assigned (i.e., application, Web, or database server). This can be done by attaching an HPE OO flow to the post-deployment stage and then in-voking custom scripts from the HPE OO

flows. For the DayTrader application, the scripts perform tasks such as:

• Modifying the Apache Web server configuration file to redirect Day-Trader application requests to the Geronimo application server

• Configuring the database client connection in the Geronimo ap-plication server to connect to the MySQL database instance

• Setting up the load balancer VMs (in medium and large service of-ferings) to forward requests to the appropriate Web and application server VM instances HPE OO scripts these configurations in an automated fashion. The HPE OO flow then gath-ers information from the VMs and configures each tier appropriately. Manually configuring these settings would have been time-consuming and error prone, and HPE OO flows reduces this effort significantly.

Page 13: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 13

Figure 12: HPE CSA Marketplace Portal

Subscribing and Accessing the Application

The HPE CSA service catalog can be ac-cessed from the HPE CSA Marketplace portal. It lists every service to which a user can request. This may include a small, medium, or large service com-

ponent. Once subscribed, the user can monitor the status of the service com-ponents using the portal.

When the service deploys, the details to access the application can be viewed by clicking on the service name in the HPE CSA portal.

The end user can request a new service (such as the DayTrader medium con-figuration) by following the easy steps listed as follows:

1. Create a new service request From the HPE CSA Marketplace Portal, select the DayTrader Medium Offering and “checkout” the service in the following

screen.

Page 14: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

14Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Figure 13: Submit a New Service Request

Provide a subscription name for the request and submit the request.

2. View service details

Once the subscription request is completed, the details of the newly created service can be accessed by clicking on “My Services” link in the HPE CSA Marketplace dashboard.

Figure 14: Service Details

Page 15: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 15

Migration Recommendations

Migrating applications and data can be a risky, time-consuming, and costly process, whether done manually or using solutions lacking fully automated features. Often applications must be migrated one at a time, taken out of production (disrupting business), necessitating downtime, and requiring highly skilled human resources. HPE Workload Portability Services can help customers define the right migration strategy, using tools and experienced consultants to simplify the overall ap-plication migration to cloud project.

For the DayTrader application used as an example in this document, some of the migration challenges include the following:

• Migration of Apache Web server con-figuration and data

• Migration of DayTrader Java applica-tion packages into Geronimo applica-tion server, and

• Migration of existing data into the MySQL database instance

Apache Web Server Migration

Migration of the Apache Web server data and configurations to the new environment is primarily a two-step process:

1. Copy (using scp or rsync tool) the Apache Web server configurations from the source environment to the new environment

$ scp /etc/httpd/conf/httpd.conf user@target_host:/etc/httpd/conf

$ scp /etc/httpd/conf/workers. properties user@target_host:/etc/httpd/conf

2. Copy (using scp or rsync tool) the Web pages and content from the source to the new environment. The location of the Web root folder is mentioned by the DocumentRoot directive in the httpd.conf file:

$ scp /var/www/html/* user@tar-get_host:/var/www/html

Geronimo Application Server Migration

Migrating applications from the Geronimo application server can be a straightforward task for applications that do not require modifications to the Web application deployment plan. This migration can be performed by copying over the Web application archive (.war files) from the source environment to the new environment, and then using the Geronimo deploy tool to install the application.

Following are the steps to migrate Geronimo applications:

1. Copy the Web application archive file (.war) to the new environment

$ scp <geronimo_app_home>\DayTrader.war user@target_host: <geronimo_app_home>\DayTrader.war

2. Deploy the new application into Geronimo

$ deploy --user <user> --password <password> deploy <geronimo_app_home>\DayTrader.war

Geronimo application server instance-specific configurations are stored in the config.xml file. This file can be copied over from the source environment to the new environment.

Database Server Migration

MySQL also provides command line utilities to dump (mysqldump) the data into a file and to import (msyqlimport) it into a new instance of the database. Following are steps that you can take to migrate data using the dump and import utilities.

1. In the current environment, stop any application server connections to the MySQL database instance. Stop the MySQL server and obtain a read-only lock on the tables that

need to be backed up by entering the following commands on the MySQL console:

FLUSH TABLES tbl_list WITH READ LOCK;

SET GLOBAL read_only = ON; EXIT

2. Export the data using the mysql-dump tool to a file name source_dump.sql

$ mysqldump --lock-all-tables -u root -p --all-databases > source_dump.sql

3. Copy the source_dump.sql file from the source to the target server host

$ scp source_dump.sql user@tar-get_host:/tmp

4. Import the source database into the MySQL instance on the target_host

$ mysql -u root -p < /tmp/source_dump.sql

Another alternative method would be to use the MySQL Workbench utility to export and import the data into the new environment. This method is discussed in the Appendix section Database mi-gration using MySQL Workbench.

For customers with a large number of application instances to be migrated, performing the manual migration steps listed earlier (as an example) can be time-consuming. These applica-tion and data migration steps can be automated using HPE CSA and HPE OO, and we demonstrate this by migrating an Apache Web server configuration file using these tools in the next section.

Automating Migrations Using HPE CSA and HPE OO

HPE CSA and HPE OO can be leveraged to perform automated application con-figuration and data migration as well by developing custom OO flows. As an example, an HPE CSA service offering can be created to automate the Web server configuration migrations. The service offering depicted in figure 15,

Page 16: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

16Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

is an example of such a service offering that can be built to accept the source environment and target environment IP addresses, and automatically migrate the Web server configurations.

Methods to migrate application files and data are very product specific and can vary depending upon individual ap-plication workloads.

Hewlett Packard Enterprise consultants can assist you in building migration strategies and automation procedures for different types of software products.

Figure 15: Web Server Configuration Migration Service

Summary

In this document, we have demonstrat-ed an approach to migrate a 3-tier ap-plication to a private cloud environment leveraging the automation capabilities of HPE CSA. This solution approach can help you reduce the time and risk involved in migrating your applications to a private cloud environment. The so-lution discussed in this document can be generalized and easily applied to migrating any other application work-loads to a private cloud environment built using Hewlett Packard Enterprise products and technologies.

References

Apache JMeter: jmeter.apache.org/

DayTrader Application documentation: geronimo.apache.org/GMOxDOC22/daytrader-a-more-complex-applica-tion.html

HPE Cloud Service Automation: www8.hp.com/us/en/software-solutions/cloud-service-automation/

HPE Operations Orchestration: www8.hp.com/us/en/software-solutions/operations-orchestration-it-process-automation/index.html

VMware vCenter: vmware.com/prod-ucts/vcenter-server

VMware ESXi: vmware.com/products/esxi-and-esx/overview.html

Page 17: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

SOFTWARE INVENTORY

SOFTWARE COMPONENT VERSION

HPE Cloud Service Automation V4.5

HPE Operations Orchestration Studio V10.21

VMware vCenter Server V5.5

Geronimo Application Server V3.0.1

Apache httpd server Apache/2.2.15

MySQL database V5.1.73

DayTrader Application J2EE 1.4, EJB 2.1

17

Appendix

Solution Sizing and Testing Methodology

For the DayTrader application, we have created small, medium, and large configurations targeted to handle a 500, 5000, and 20000 user load. These configurations differ both in terms of the size of the VM (different CPU and memory quantities) and the number of VMs deployed at each tier (Web/appli-cation/database).

Details of the three configurations tested for this reference architecture, along with the approximate number of users supported, is provided in table 1.

To validate the sizing of each of the service offering, load testing was car-ried out using the JMeter tool. JMeter executes several use cases pertaining to the application deployed, which includes simulating users connecting to the system, requesting pages, and performing various actions.

These JMeter scripts were run against DayTrader to observe the number of user requests it can support for each of the service offering configurations.

Sizing Recommendations

During load testing of DayTrader, each tier of the workload behaved differently as loads increased.

The Web server tier accepts incom-ing requests from the clients. It then spawns a process for handling each of the incoming requests.

The Web server tier requires adequate network and CPU resources to handle the incoming requests and is amenable to horizontal scaling using additional VMs to distribute the load. A load bal-ancer VM front ending the Web server tier was used to distribute the incoming client requests uniformly across the Web server instances.

The application server tier spawns Java processes to handle client requests. Java processes are typically memory intensive. To help the application server tier scale, the VM memory size should be increased.

The database tier running MySQL database is CPU intensive, and the per-formance at this tier can be improved by providing additional vCPUs to the virtual machine.

Note: The sizing recommendations provided in this section are generic and applicable to the DayTrader Application only. HPE presales engineers can help assess and size a solution for your specific application work-loads with the right hardware and software configurations.

Page 18: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

TABLE 1: VM SIZES FOR SMALL, MEDIUM, LARGE CONFIGURATION

SERVICE OFFERING SIZE CONFIGURATION DETAILSNUMBER OF USER REQUESTS SUPPORTED

Small Web serverCount: 1VM configuration: 2 vCPUs, 2 GB RAM, 20 GB disk

500

Application serverCount: 1VM configuration: 2 vCPUs, 2 GB RAM, 20 GB disk

Database serverCount: 1VM configuration: 2 vCPUs, 2 GB RAM, 20 GB disk

Medium Load balancer for Web serverCount: 1VM configuration: 2 vCPUs, 4 GB RAM, 20 GB disk

5000

Web serverCount: 2VM configuration: 2 vCPUs, 4 GB RAM, 20 GB disk

Application serverCount: 1VM configuration: 6 vCPUs, 12 GB RAM, 20 GB disk 1, 40 GB disk 2

Database serverCount: 1VM configuration: 8 vCPUs, 12 GB RAM, 20 GB disk 1, 40 GB disk 2

Large Load balancer for Web serverCount: 1VM configuration: 2 vCPUs, 4 GB RAM, 20 GB disk

20000

Web serverCount: 4VM configuration: 2 vCPUs, 4 GB RAM, 20 GB disk

Load balancer for application serverCount: 1VM configuration: 2 vCPUs, 4 GB RAM, 20 GB disk

Application serverCount: 2VM configuration: 8 vCPUs, 12 GB RAM, 20 GB disk 1, 40 GB disk 2

Database serverCount: 1VM configuration: 12 vCPUs, 16 GB RAM, 20 GB disk 1, 40 GB disk 2

18Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Page 19: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud 19

Database Migration Using MySQL Workbench

This section describes an alternate MySQL database migration approach, using the MySQL Workbench tool. MySQL Workbench provides a graphi-cal user interface to help users select a source MySQL database instance and export the data into a file. Subse-quently, the user can select the target database server instance and import the data.

Following are the steps illustrating this process for the DayTrader tradedb da-tabase, which can be migrated over into simple steps.

Figure 16: MySQL Workbench—Source Database Selection

Figure 17: Mysql Workbench—Data Export Status Screen

1. Export the existing tradedb database from the current environment using MySQL Workbench.

Page 20: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

ACRONYMS

SERVICE OFFERING SIZE CONFIGURATION DETAILS

HPE Hewlett Packard Enterprise

CSA Cloud Service Automation

OO Operations Orchestration

VM Virtual machine

OS Operating system

Learn more at hpe.com/solutions/App2Cloud

20Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud

Figure 18: MySQL Workbench—Import Database into Target Server

2. Import the database into the new environment using the MySQL Workbench tool.

Page 21: Migrate a 3-Tier Web Application to a Private Cloud · REFERENCE ARCHITECTURE Intel® Cloud uilders Hewlett Packard nterprise Executive Summary Cloud is critical to delivering the

DisclaimersThe information in this document is subject to change without notice. Every effort has been made in the preparation of this document to ensure accuracy of the contents, but all statements, information, and

recommendations in this document do not constitute a warranty of any kind, express or implied. INFORMATION IN THIS DOCUMENT IS PROVIDED IN CONNECTION WITH INTEL® PRODUCTS. NO LICENSE, EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, TO ANY INTELLECTUAL PROPERTY RIGHTS IS GRANTED BY THIS DOCUMENT. EXCEPT AS PROVIDED IN INTEL’S TERMS AND CONDITIONS OF SALE FOR SUCH PRODUCTS, INTEL ASSUMES NO LIABILITY WHATSOEVER, AND INTEL DISCLAIMS ANY EXPRESS OR IMPLIED WARRANTY, RELATING TO SALE AND/OR USE OF INTEL PRODUCTS INCLUDING LIABILITY OR WARRANTIES RELATING TO FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT. UNLESS OTHERWISE AGREED IN WRITING BY INTEL, THE INTEL PRODUCTS ARE NOT DESIGNED NOR INTENDED FOR ANY APPLICATION IN WHICH THE FAILURE OF THE INTEL PRODUCT COULD CREATE A SITUATION WHERE PERSONAL INJURY OR DEATH MAY OCCUR.

Intel may make changes to specifications and product descriptions at any time, without notice. Designers must not rely on the absence or characteristics of any features or instructions marked “reserved” or “undefined.” Intel reserves these for future definition and shall have no responsibility whatsoever for conflicts or incompatibilities arising from future changes to them. The information here is subject to change without notice. Do not finalize a design with this information.

The products described in this document may contain design defects or errors known as errata which may cause the product to deviate from published specifications. Current characterized errata are available on request. Contact your local Intel sales office or your distributor to obtain the latest specifications and before placing your product order. Copies of documents which have an order number and are referenced in this document, or other Intel literature, may be obtained by calling 1-00-548-4725, or by visiting Intel’s Web site at www.intel.com.

© Copyright 2015 Hewlett Packard Enterprise Development LP. The information contained herein is subject to change without notice. The only warranties for Hewlett Packard Enterprise products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. Hewlett Packard Enterprise shall not be liable for technical or editorial errors or omissions contained herein.

Java is a registered trademark of Oracle and/or its affiliates. VMware is a registered trademark or trademark of VMware, Inc. in the United States and/or other jurisdictions.

4AA6-2821ENW, December 2015

Copyright © 2016 Intel Corporation. All rights reserved. Intel and the Intel logo are trademarks of Intel Corporation in the U.S. and/or other countries.

* Other names and brands may be claimed as the property of others. Printed in USA 0316/HDW/MM/PDF Please Recycle

Reference Architecture: Migrate a 3-Tier Web Application to a Private Cloud