VMworld 2011 Session BCA1950 – Production Proven Methods of Running Enterprise Java on vSphere

This is a live update from VMworld! These are just my notes during the session, please forgive the grammatical errors, I am sure I missed parts of the lecture as I am taking notes…

This session had excellent information, though I wasn’t able to capture some of it. I will review the recording once it is released and fill in the missing information. Also, I had to leave about 45 minutes into the presentation for another meeting, so be sure to check out the actual session recording at http://www.VMworld.com – search for the session using the session identifier in my blog post title.

Well, the display failed right at the beginning, so we had a 10 minute delay as they switched laptops… Nothing like technology to mess up a discussion about technology!

Conventional Enteprise Java-
– apps are multiple-tier
– load balancers can be virtualized
– web servers can be virtualized
– application servers can be virtualized
– database svrs can be virtualized
– development platform lends itself to virtualization, especially vFabric

3 Step process to production virtualized Java
1- establish your load profile
2- establish your benchmark

focus on Step 2
scale up testing… How BIG does my VM need to be (vCPU, RAM, etc)?
– this is your building block for Scale OUT testing
Scale out testing…
– this determines how MANY vms you can run on a host… You want to keep all the vms the same, as it simplifies the load balancer logic (rather than using weighted rules for different-sized vms)

In our testing, we have seen linear scale-out up to 80% native performance. for most Java web apps, they virtualized easily. If you find the scale out testing fails, identify the bottleneck layer, resolve and retest.

Once your single-host scale out testing is complete, turn on DRS to perform multiple host testing.

Sizing the vm/JVM
– most common misconception- java
– Every click on the page from a user turns into a thread in the JVM (-Xss per thread) in the
Java stack
– Java heap max (-Xmx)
– perm Gen (inside the heap)

VM memory=guest os memory+JVM max heap(-Xmx value)+JVM perm size (-XX:maxpermsize)+ (# concurrent threads * -Xss per thread)+ other memory

note that the above equation will show that the memory allocated to Java can frequently be undersized, as programmer and administrators don’t always take all factors into consideration

See the java best practices white paper:
http://www.VMWare.com/resources/tech resources/1087

Set the memory reservation to equal active RAM (or configured vm)
Use large pages (-XXlargepages/-XX:+Uselargepages)
leave hyper threading ON
Enable DRS and HA
Use latest hardware and vSphere
Use load balancers that integrate well with vSphere APIs
Keep the vms symmetrical to simplify the load balancing algorithm
Establish appropriate thread ratios that prevent bottlenecks
– http threads:java threads:db connections… Start with 1:1:1
Googlebot is a very aggressive crawler and can degrade performance…. Best to divert the bot to static pages…

High availability phase 1
Establish Zero Downtime Release schedule
Step 1- make a production replica
Step 2- switch from production using load balancing mechanisms
Step 3- take snapshot of production vms, begin application deployment release using master deployment script (see example in the session recording at VMworld.com)
Step 4-
Step 5- switch users to new production using load balancers

High availability phase 2
establish dynamic scalability
– vertical scalability… Hot add vCPU and RAM… You must enable this feature in the vm and the guest
– horizontal scalability…. Use VMware DRS for host horizontal scalability; use load balancers that have vCenter integration to be aware of when virtual machines are added to the load balanced tier

High availability phase 3
Establish disaster recovery/ operational recovery

Migrating to a vitualized implementatins – key considerations
– from Unix to Linux; large pages is on by default in Unix, must explicitly enable it in Linux
– 32 bit to 64 bit

Performance perspective
We found consistently a 2 vCPU vm scales better than 4+ vCPU

A representative from Cardinal Health spoke to illustrate their virtualized Java environment.

– Posted using BlogPress…

Location:Winnick Ave,Las Vegas,United States

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s