Posts Tagged ‘VMware’

He sed / she sed

November 14th, 2008

Sed (Stream EDitor) is a powerful Unix and Linux utility which has the ability to parse text files and make changes.  It’s practically a gold mine for scripting.  Fortunately, this utility has been part of the modified Red Hat Enterprise Linux service console (COS) in VMware ESX current and previous versions.  Used in my deployment scripts, it serves me well for the purposes of rapidly standing up new or rebuilding existing ESX hosts.

Admittedly, I don’t have a real strong Linux background.  My foundation has been primarily Microsoft Windows, and before Windows, Microsoft DOS and Commodore 64/VIC-20 BASIC programming which actually did provide me a nice basis for command line going forward.  When I began building ESX hosts, I soon discovered scripting was where it’s at for efficiency and more imporantly consistency.  I learned the use of sed by borrowing snippets of example code available on the internet and VMware Community forums.  By the way, the sed rabbit hole goes very deep.  I’ve only learned the find/replace function of it to get me by for ESX scripting which is just the tip of the iceberg.

I learned something about sed recently that probably would have helped me during my learning process of sed a while back.  The majority of sed examples found on the internet (and probably in the man pages) use a forward slash / as the delimiter.  This is because the / is natively used in ed, more, and vi.  What I discovered is that any character can actually be used as a delimiter.  This would have been helpful for me to know earlier because some of the scripting I do involves Linux paths which of course make use of the forward slash.  Adding an additional forward slash for sed scripting made for an awful lot of forward slashes in one line and at times made my eyes hurt.  Similar to building a complex Microsoft Excel formula whith a lot of parentheses and trying to keep track of the number of open parens versus the number of close parens. 

Let me show a few examples and maybe you can see what I’m talking about.

Here’s one line of an actual script I use to add the full path display in the COS (there are three / delimiters in this example, see if you can find them):

sed -e “s/\\h \\\W/\\h \\\w/g” /etc/bashrc.old > /etc/bashrc

Forward and backwards slashes that butt up against each other are commonly reffered to as “the picket fence effect”.  In the example above, for my sanity I could have chosen a different delimiter, such as an underscore, so that the script looked like this instead:

sed -e “s_\\h \\\W_\\h \\\w_g” /etc/bashrc.old > /etc/bashrc

Here’s another example which prevents the VMFS2 module from loading at startup on ESX3 hosts:

sed -e “s/echo \”vmfs2 vmfs2\”/\#echo \”vmfs2 vmfs2\”/g” /etc/init.d/vmware.old > /etc/init.d/vmware

More picket fence, not quite as bad though.  Maybe this time I use use the asterisk as a delimiter so that it looks like this instead:

sed -e “s*echo \”vmfs2 vmfs2\”*\#echo \”vmfs2 vmfs2\”*g” /etc/init.d/vmware.old > /etc/init.d/vmware

So it boils down to choosing the right sed delimiter for the line of code you’re working with.  Kind of like choosing the right bottle of wine for your meal, and choosing the right cigar for afterwards.

I’ve always said that much of the fun of this career I have chosen is the opportunity to learn something new every day and put it to practical use.  Today has been no exception.  Some days are more fun to learn than others.  It depends on the conditions and circumstances…

Make VirtualCenter highly available with Microsoft Cluster Services

November 12th, 2008

When VirtualCenter was first introduced, many could make the argument that VC was simply a utility class service that provided centralized management for a virtual infrastructure. If the VirtualCenter Management Server (VCMS) was rebooted in the middle of the day or if the VC services were stopped for some reason, it wasn’t too big of a deal providing the outage didn’t interrupt a key task such as a VMotion migration or a cloning process.

Times are changing. VirtualCenter is becoming a fairly critical component in the VI and high availability of VC and the VCMS is becoming increasingly important. Several factors have contributed to this evolution. To identify just a few:

  • Virtual infrastructures are growing rapidly in the datacenter. The need for a functioning centralized management platform increases exponentially.
  • Increased and more granular VC alerting capabilities are relied upon to keep administrators updated with timely information about the load and health of the VI.
  • The introduction of more granular role base security extended Virtual Infrastructure Client or Web Access deployment to more users and groups in the organization increasing dependability on VC and visibility of downtime.
  • The exposure of the VC API/SDK encouraged many new applications and tools to be written against VC. I’m talking about tools that provide important functions such as backup, reporting, automation, replication, capacity analysis, sVMotion, etc. Without VC running, these tools won’t work.
  • The introduction of plugins. Plugins are going to be the preferred bolt on for most administrators because they snap in to a unified management interface. Obvious dependency on VC.
  • The introduction of new features native to VC functionality. DRS, HA, DPM, VCB, Update Manager, Consolidation, snapshot manager, FT, SRM, etc. Like the bullet above, all of these features require a healthy functioning VCMS.
  • The Virtual Datacenter OS was announced at VMworld 2008 and is comprised of the following essential components: Application vServices, Infrastructure vServices, Cloud vServices, and Management vServices. I don’t know about you, but to me those all sound like services that would need to be highly available. While it is not yet known exactly how existing VI components transform into the VDC-OS, we know the components are going to be integral to VMware’s vision and commitment to cloud computing which needs to be highly available, if not continuously available.

VirtualCenter has evolved from a cornerstone of ESX host management into the the entire foundation on which the VI will be built on. Try to imagine what the impacts will be in your environment if and when VirtualCenter is down now and in the future. Dependencies may have waltzed in that you didn’t realize.

A single VCMS design may be what you’re used to, but fortunately there exists a method by which VC may be made highly available on a multi-node Microsoft Cluster. This document, written by none other than my VI classroom training instructor Chris Skinner, explains how to cluster VirtualCenter 2.5.

If you’re on VirtualCenter 2.0.x, follow this version of the document instead.

Update:  Follow up post here.

VMware Communities using Hyper-V Quick Migration during business hours?

November 12th, 2008

The VMware Communities are down this morning for what I’m hoping is unplanned maintenance. Hopefully they get all of the kinks worked out.

If it was planned maintenance (the outage message does mention “system upgrade”), VMware, please – not during business hours.

vmwmaint

Live migration between CPU vendors demonstrated by AMD and Red Hat

November 11th, 2008

Live migration (VMotion in VMware speak) across AMD and Intel processors is a feature we don’t have today and a technology that many would describe as nearly impossible.

The capability could be in your datacenter sooner than you think. Last Thursday, the Inquirer published an article along with a video where Red Hat and AMD demonstrate the process (of course using streaming video and sound to drive home the point of no interruption) proving that it is possible and the technology to do so may not be so far off. The article goes on to explain that not only can live migration occur between CPU vendors, the same or similar technology can be used to live migrate between CPU architectures from the same vendor (ie. AMD Barcelona Opteron <–> AMD Shanghai Opteron).

Take a look at the video:

Rob Bergin leaves VKernel

November 10th, 2008

Rob Bergin, who maintained the titles of Director of Systems Engineering, Director of Product Marketing, and Systems Engineer, has parted ways with the New Hampshire startup company VKernel. During Rob’s nine month tenure at VKernel, his responsibilities included development of the product roadmap strategy, documentation and creation of new features, and management of timely product release cycles.

VKernel provides 3rd party management applications for VMware Virtual Infrastructure. Their product lineup includes:

  • Capacity Analyzer
  • Chargeback
  • Modeler (announced 9/9/08)
  • and the recently announced SearchMyVM product which, strangely, is difficult to find any information for on VKernel’s website – a SearchMyVM press release links to their Modeler product

I wish Rob the best of luck in his new role of Director of Enterprise Infrastructure at CrunchTime! Information Systems.

Rob, if you get that lab hardware website up and running, let me know.

VMware employee confirms DPM support in next release

November 10th, 2008

There’s been some recent excitement circulating the internet around a VMware Virtual Infrastructure feature called Distributed Power Management (DPM).  An impactful video demonstration of DPM was put together by VMware engineers two months ago and released on YouTube.  I’m sure you’ve seen it already by now on the other blogs but I’ve provided a copy below in case you have not seen it.

DPM is currently in experimental status, however, Richard Garsthagen, a Senior Evangelist for VMware in EMEA (and a great conversationalist if you ever get the chance to have dinner with him), tells us in his blog that DPM “will be fully supported with the next release.”  What exactly does next release mean?  That’s a good question but we can safely assume one of two things:  Update 4, or the next generation of Virtual Infrastructure which many, including myself, are unoffically calling VI4.

This is great news because DPM support is finally going to unlock additional potential for savings in the datacenter:

  • Kilowatt consumption for powering the VI goes down
  • Kilowatt consumption for cooling the VI goes down
  • Consolidation of VMs offers increased opportunity for VMware Content Based Page Sharing resulting in more effective use of physical RAM and increased consolidation ratios
  • Saving more of the environment means Green rating goes up (take a look at this great green calculator)

In the midst of all this excitement, we must not lose sight of the fact that a properly architected cluster should support a minimum of N+1 capacity.  The goal should not be to simply shut down as many hosts as possible in the name of efficiency and saving the environment.  This mindset will compromise uptime of VMs in the event of a host failure.  Leave enough room in the cluster for HA to perform its responsibiity of powering on VMs on another available host.

VMware earns multiple Redmond Triple Crown awards

November 8th, 2008

The November 2008 issue of Redmond magzine, the independent voice for the Microsoft IT community and formerly known as Microsoft Certified Professional Magazine, is bubbling over with VMWare virtualization news this month.  They have announced the 2008 Reader’s Choice Awards Triple Crown achievers.  The prestigious Triple Crown award is described by Redmond as follows:

“To recognize the dynasties in our annual Readers’ Choice competition, Redmond is introducing the “Triple Crown,” a new award for products that have won (at least) three Readers’ Choice honors in a row.”

VMware GSX Server (retired but replaced by the free VMware Server) won the Triple Crown in the “Best Virtual Server Product” category as well as taking “ISV Winner” honors.  Redmond goes on to explain GSX easily won over Microsoft Virtual Server 2005 which was the only other product in the category.  No surprises there.  Like today’s comparison of VMware ESX and ESXi to Microsoft Hyper-V, GSX Server was years ahead of Microsoft in terms of development.

VMware Workstation dominated the more competitive “Best Virtual PC Product” field (5 products) and, like VMware GSX Server, was also named “ISV Winner”.  Microsoft Virtual PC for Windows, a technology Microsoft bought its way into by purchasing from Connectix in February 2003 along with Virtual Server, was honorably mentioned as a runner up.  Microsoft came to the realization that the product they had been developing was not capable and started over from scratch.  VMware’s latest Workstation 6.5 offering is sure to continue embarrassing the competition with features like Unity and enhanced record and reply technology.

Read more about Redmond’s virtualization category and other categories here.

The same issue also contains three other VMware related articles:

  1. Maritz:  VMware’s Answer to Microsoft?”  An interview with VMware CEO Paul Maritz whom they labeled “The Microsoft Menace” on the issue’s cover.
  2. VMware Wants It All” Editor In Chief Doug Barney talks about VMware’s future technology announcements and contemplates how they will fit together and will they work?
  3. Cisco and VMware Collaborate on Next-Gen Data Center” The companies’ new products could change the virtualization game.