Managing heterogeneous data centers with PowerShell

Source: Internet
Author: User
Tags virtual environment

Do not object to other virtualization platforms entering your data center. Organizations often need lower costs or need to find alternative solutions, and IT professionals often face challenges in managing heterogeneous virtual environments. Do not let this challenge exceed the necessary limits. As an IT professional, you should focus on a unified management platform, reduce the learning curve, and always maintain the flexibility to control a large number of systems in heterogeneous data centers.

Is the graphical management tool the solution?

When you understand the differences between different vendor virtualization platforms, the challenge is to manage these platforms. You don't want to waste time and investment costs on tools that don't meet your needs.

Many IT pros first tend to find a GUI tool to help them manage the entire heterogeneous data center. Graphics tools have the advantage of being easy to use, including wizards to complete complex tasks and providing graphical display capabilities.

Many virtualization platform vendors, such as VMware and Microsoft, have introduced GUI management tools to help manage other vendors ' products. These tools provide a unified interface, reduce confusion and training costs, and third party management products provide the same functionality. Despite the advantages of interface unification, the use of GUI management tools takes into account some of the drawbacks of its existence:

? You can only perform the GUI management tasks that have been developed by the manufacturer and have difficulty in performing tasks that are not developed.

? When a manufacturer tries to manage the products of other vendors through a graphical interface, it encounters cross-platform management problems and has countless limitations.

? Graphics management tools often do not provide many automation capabilities, and tasks must be repeated multiple times.

? Installing the GUI tool on the client is not always easy when you need to use it.

It takes time and testing to weigh the pros and cons of a particular graphics management tool. This is often true of graphical tools. However, as an IT professional who needs to work on a variety of platforms and need to automate, I don't want to waste time on tools that limit my ability.

The most powerful choice of existence and flexibility

I'm focused on using PowerShell rather than wasting time researching graphics management tools. Before you begin to express your anger to me, let me cite an example to illustrate some of PowerShell's strengths and weaknesses.

PowerShell can span multiple virtualization platforms. Cmdlets is suitable for most popular virtualization platforms, including VMware (POWERCLI), Microsoft (SCVMM and Hyper-V), and Citrix (XenDesktop). PowerShell provides sufficient flexibility for the enterprise to handle all issues. Say goodbye to the limitations of using GUI tools, and you can also use automation to eliminate repetitive tasks that are often performed when using graphical tools. Automation also excludes the possibility of human error.

Of course, there are also drawbacks when using shell and scripting languages like PowerShell. You can ask any experienced UNIX administrator to learn and use tools that can be difficult and can be invested with a lot of effort. There are some very good resources available--including books, videos and training classes--but you need to sit down and practice instead of just gathering information.

The use of PowerShell requires some research. Using some simple commands does not solve all the problems. Many times, you need to study the problem and then write a script to solve it. Sometimes it may take hours to soak on the MSDN Web site, and you need to learn development skills. You don't need to be a well-rounded developer, but you need to learn scripts and programming skills.

Once you know which management tools are more appropriate for your organization and your virtual environment, many IT pros will choose PowerShell to manage heterogeneous data centers.

Start cross-platform management

The following examples describe some of the features that PowerShell can provide by entering commands at the PowerShell command prompt.

First, flexible and scalable management capabilities are provided by loading multiple modules rather than providing additional cmdlets,powershell. If the manufacturer has created the appropriate modules and you have installed the tools on your local computer, you can load and use these modules to manage heterogeneous data centers. The following example shows how to load the cmdlets for managing VMware:

Ps> Add-pssnapin vmware*

You can load multiple modules and create automated management scripts for multiple products. In the following example, I loaded VMware and Microsoft SCVMM cmdlets. Note that there may be conflicts when multiple vendors use the same cmdlet name. If cmdlets belongs to a module, then the Import-module cmdlet provides a parameter-prefix that avoids conflicts by adding a prefix before the cmdlet:

Ps> Add-pssnapin vmware*

ps> import-module–name Virtualmachinemanager-prefix MS

Usually I don't want to install the administration Tools on my computer. PowerShell has a PowerShell remoting feature that allows you to borrow cmdlets that are already installed on the server. The cmdlets that appears on your computer is like installing on a local computer, or more accurately, a shortcut to a cmdlets installed on a remote server. The following example invokes a remote cmdlets that is suitable for VMware, Citrix, and SCVMM. However, when you do the experiment, you will find that not all vendors are planning for this, and may find some cmdlets unusable.

#VMware

$VWsession = New-pssession-computername "Nameofvmwareserver"

Invoke-command-session $VWsession-scriptblock {add-pssnapin vmware*}

Import-pssession-session $VWsession-module vmware*-prefix VW

#Citrix

$CXSession = New-pssession-computername "Nameofcitrixzendesktopserver"

Invoke-command-session $CXSession-scriptblock {add-pssnapin citrix*}

Import-pssession-session $CXSession-module citrix*-prefix CX

#MS SCVMM

$MSsession = New-pssession-computername "Nameofscvmmserver"

Invoke-command–session $MSSession-scriptblock {import-module–name Virtualmachinemanager}

Import-pssession-session $MSsession-module Virtualmachinemanager-prefix MS

If you have already started using PowerShell, I hope this article will provide you with some ideas on how to manage multiple virtualization platforms. If you're not using PowerShell, it's time to consider the tools to achieve flexibility and maximize automation.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.