Quantcast
Viewing all articles
Browse latest Browse all 1001

Consistent Server Virtual Disk Configuration for Exchange Databases using Dell PowerEdge PowerShell Tools

In an earlier post, we looked at the building block architecture for Microsoft Exchange 2013 deployments using PowerEdge R730xd. In the Pod architecture, each server in the deployment has a standard configuration. Each PowerEdge R730xd server in the reference implementations described in my earlier post has 16 LFF NL-SAS drives that are configured in a specific manner for storing Exchange databases. In the scale-up scenarios, an additional 12 LFF NL-SAS drives are used. This RAID virtual disk configuration must be consistent across all the servers for better manageability.

Configuring servers consistently ensures predictability and reduces variables while troubleshooting deployment issues. System management tools and automation help achieve this consistency with far less effort while reducing human error during solution deployment. While multiple system components must be configured before we complete the solution deployment, for today’s article, we’ll limit the discussion to creation of virtual disks to store Exchange databases. As a reference for this virtual disk configuration, we’ll use the disk layout described in an Exchange 2013 solution implementation on Dell PowerEdge R730xd servers. The following figure provides a high-level overview of the disk layout used in the reference implementation.

Image may be NSFW.
Clik here to view.

Figure 1 RAID LUNs required for Exchange Databases

The Large Form-Factor (LFF) chassis configuration of PowerEdge R730xd contains sixteen 4TB NL-SAS drives. The internal drive tray can host up to four of these drives. This is shown in Figure 1. The LFF drives in the front bay are numbered from 0 to 11 and the LFF drives in the internal drive tray are numbered from 14 to 17. The 2.5-inch SAS drives at the rear are used for deploying OS and these are numbered as disk 12 and 13.

The recommended layout for all RAID disks in the system is shown in Table 1.

Table 1 Recommended RAID layout in PowerEdge R730xd for Exchange deployment

RAID Volume

Disks

RAID Level

OS-Volume

Disk 12 & Disk 13

RAID 1

DB-Volume1

Disk 0 & Disk 1

RAID 1

DB-Volume2

Disk 2 & Disk 3

RAID 1

DB-Volume3

Disk 4 & Disk 5

RAID 1

DB-Volume4

Disk 6 & Disk 7

RAID 1

DB-Volume5

Disk 8 & Disk 9

RAID 1

DB-Volume6

Disk 10 & Disk 11

RAID 1

DB-Volume7

Disk 14 & Disk 15

RAID 1

Restore-Volume

Disk 16

RAID 0

Global-Hot-Spare

Disk 17

RAID 0

Apart from the RAID layout, the block size for these virtual disks should be set to 512.

To achieve consistent virtual disk configuration across servers, the RAID layout described in Table 1 must be translated into a re-usable template. This is where Dell’s systems management tools can help. The WS-Management interfaces on iDRAC help you export a system or component configuration as a Server Configuration Profile (represented as an XML file) and restore or import the configuration on a different system.

To access WS-Management interfaces using Windows PowerShell, you need to understand various Common Information Model (CIM) profiles available on iDRAC, identify the right CIM classes and methods to perform RAID device configuration, and finally use those interfaces in PowerShell through CIM Cmdlets. This is not easy to do without knowing how to use CIM profiles and PowerShell CIM cmdlets. The systems management team at Dell recently announced an experimental release of PowerShell Tools for Dell PowerEdge Servers. Using the cmdlets in this experimental release, you can export component configurations and import them on a different server is as easily as using any other PowerShell cmdlet.

The two cmdlets that we will explore in today’s article are Export-PEServerConfigurationProfile and Import-PEServerConfigurationProfile. The first cmdlet exports the component configuration to a network share and the later imports it to deploy the Server Configuration Profile.

Before you use these cmdlets,

Starting with PowerShell 3.0, if you have not disabled auto module loading, the cmdlets from any available module can be directly accessed without explicitly importing the module using the Import-Module cmdlet.

Using the Get-Help cmdlet, you can see a list of examples on how to use the Export and Import System Configuration Profile cmdlets.

Get-Help Export-PEServerConfigurationProfile

Image may be NSFW.
Clik here to view.

You also can see a list of examples about how to use these Cmdlets by adding the –Examples switch parameter with the Get-Help cmdlet. Each of these cmdlets requires a CIM session created to the iDRAC of the server we’re going to manage. This is done using the Get-PEDRACSession cmdlet.

#Credentials for accessing iDRAC

$DRACCredential = Get-Credential

#Create a CIM session

$DRACSession = New-PEDRACSession -IPAddress 10.94.214.63 -Credential $DRACCredential

Once we have the DRAC session created, we can use the Export-PEServerConfigurationProfile cmdlet to export existing virtual disk configuration to an XML file. When using this cmdlet, we need to provide the NFS or CIFS share details along with the credentials required, if any, to access to the share. The Get-PEConfigurationShare cmdlet provides a method to construct a custom PowerShell object representing a CIFS or NFS share. Optionally, using –Validate parameter, you can also test if the network share is accessible from iDRAC or not.

#Share object creation for re-use

$ShareCredential = Get-Credential -Message 'Enter credentials for share authentication'

#-Validate switch ensures that the share is accessible from iDRAC.

$Share = Get-PEConfigurationShare -iDRACSession $DRACSession -IPAddress 10.94.214.100 -ShareName Config -ShareType CIFS -Credential $ShareCredential -Validate

Finally, the Export-PEServerConfigurationProfile cmdlet can be run to export the component configuration as XML.

#Export Configuration of RAID controller

Export-PEServerConfigurationProfile -ShareObject $Share -iDRACSession $DRACSession -FileName VD.xml -Target 'RAID.Integrated.1-1' -ExportUse Clone -Wait

In the above command, observe that we’re exporting the configuration of only integrated RAID controller. By default, without specifying –Target parameter, the complete system configuration will be exported.

Image may be NSFW.
Clik here to view.

You will notice in the exported configuration file that some of the attributes are commented. Importing a Server Configuration Profile on a target system that is already configured can have destructive implications--which is why some configurations are commented. Therefore, to be able to import this system on a target system, we need to uncomment these lines in the XML.

Now that you understand how the export works, using the Import-PEServerConfigurationProfile cmdlet is easy. Before we can perform the actual import, we can preview if the configuration specified in the XML can actually be deployed on a target system or not. This is done using –Preview switch parameter.

#Create a CIM session

$DRACSession = New-PEDRACSession -IPAddress 10.94.214.64 -Credential $DRACCredential

#Preview a configuration XML import

Import-PEServerConfigurationProfile -ShareObject $Share -iDRACSession $DRACSession -FileName VDGOLD.xml -Preview -Wait

If you do not see any errors after a preview, the XML configuration for the integrated RAID controller can be deployed successfully on the target system. So, to perform the deployment, we just need to remove the –Preview switch and run the Import-PEServerConfigurationProfile cmdlet again.

#Preview a configuration XML import

Import-PEServerConfigurationProfile -ShareObject $Share -iDRACSession $DRACSession -FileName VDGOLD.xml -Wait

The –Wait switch parameter ensures that a progress bar is shown to indicate what tasks are being performed while importing the Server Configuration Profile. Once you import the configuration, the target system gets rebooted and you will see that the RAID disks get created on the integrate RAID controller.

This method of deployment is error-free and repeatable. For a system administrator, this method also provides a scripting mechanism that can be used as a part of much bigger data center automation framework.

Image may be NSFW.
Clik here to view.

Viewing all articles
Browse latest Browse all 1001

Trending Articles