Partager via


Export and Import Windows HPC Cluster Configuration Settings

Updated: July 2011

Applies To: Microsoft HPC Pack 2008 R2, Microsoft HPC Pack 2012, Microsoft HPC Pack 2012 R2, Windows HPC Server 2008 R2

In a cluster running at least Windows HPC Server 2008 R2 with Service Pack 2 (SP2), there are two HPC PowerShell scripts, Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1, which you can use to export the configuration settings from one cluster, and then import those settings to the same or another head node in the same Active Directory doMayn if it is running the same version of HPC Pack 2008 R2.

In this section:

  • Settings exported and imported by Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1

  • Run Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1

  • Sample scenarios

Settings exported and imported by Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1

Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1 can export and import the following settings that are configured on the head node:

  • Users and administrators for the cluster (excluding computer accounts)

  • Node groups

  • Node templates

  • Operating system images and drivers

  • Job templates and job template access control lists (ACLs)

  • Job scheduler configuration settings

  • Job submission and activation filter programs

  • SOA service configuration files

  • Cluster-wide configuration settings for diagnostics, reporting, management, and scheduling

You can choose to export or import all of these settings or only a subset, for example, only those settings for the job scheduler.

Limitations

  • You cannot export configuration settings from a head node in one doMayn and import them on a head node in another doMayn.

  • The following configuration settings are not handled by the scripts:

    • The contents of the HPC databases, including the job scheduling database that stores the job queue

    • Credentials, including installation credentials, eMayl credentials, diagnostics credentials, SOA session credentials, and credentials configured in node templates

    • Network configuration settings, including DHCP scopes and firewall settings

    • The following cluster-wide environment variables: CCP_MPI_NETMASK, WCF_NETWORKPREFIX, CCP_SERVICEREGISTRATION_PATH, CCP_CLUSTER_NAME, CCP_HOME, and CCP_JOBTEMPLATE

    • The following environment variables on the head node: CCP_HOME, CCP_DATA, CCP_SCHEDULER, and CCP_JOBTEMPLATE

    • Setup files for HPC Pack 2008 R2 that are stored in the REMINST share

    • Customized diagnostic tests

    • Registry settings for Windows HPC Server 2008 R2

    • DLLs for SOA services

    • Submission and activation filter programs that have dependencies on other assemblies

    • Failover clustering configuration in the case of a head node that is configured for high availability in a failover cluster

Run Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1

Important
To run these scripts, the Windows PowerShell execution policy on your head node must be configured to be AllSigned, at a minimum. For more information, see Set-ExecutionPolicy.

To export cluster configuration settings using Export-HpcConfiguration.ps1

  1. Log on to the head node of the cluster as a user with Administrator privileges.

  2. Click Start, point to All Programs, click Microsoft HPC Pack 2008 R2, right-click HPC PowerShell, and then click Run as administrator.

  3. Run the Export-HpcConfiguration.ps1 HPC PowerShell script as follows:

    • To run the script so that all cluster configurations are saved to the C:\Path folder, type:

      Export-HpcConfiguration.ps1 -Path C:\Path\

      Note
      Settings are exported to the YYYYMMDD_HHMMSS subfolder of the folder that is specified by the –Path parameter, if it is provided. The exported settings consist of the MetaData.xml file and subfolders that contain the exported files.
    • To run the script so that only the cluster configurations that are specified in the string ConfigString are saved to the C:\Path folder, type:

      Export-HpcConfiguration.ps1 -Path C:\Path\ -Configuration ConfigString

      Note
      ConfigString must be a comma-separated string that describes the cluster configuration settings to export, for example, Diagnostics,Management,Reporting,Scheduler,Soa

To import cluster configuration settings using Import-HpcConfiguration.ps1

  1. Log on to the head node of the cluster as a user with Administrator privileges.

  2. Click Start, point to All Programs, click Microsoft HPC Pack 2008 R2, right-click HPC PowerShell, and then click Run as administrator.

  3. Run the Import-HpcConfiguration.ps1 HPC PowerShell script:

    • To run the script so that all cluster configurations (which were previously exported by using Export-HpcConfiguration.ps1) are imported from a designated subfolder of the C:\Path folder (for example, 20110520_132914), type:

      Import-HpcConfiguration -Path C:\Path\20110520_132914

    • To run the script so that only the cluster configurations that are specified in the string ConfigString are imported from the C:\Path\20110520_132914 folder, type:

      Import-HpcConfiguration.ps1 -Path C:\Path\20110520_132914 -Configuration ConfigString

      Note
      ConfigString must be a comma-separated string that describes the cluster configuration settings to import, for example, Diagnostics,Management,Reporting,Scheduler,Soa
    • To run the script so that all cluster configurations are imported from the C:\Path20110520_132914 folder, and existing target cluster configurations are overwritten without prompting, type:

      Import-HpcConfiguration.ps1 -Path C:\Path\20110520_132914 -Force

Additional considerations

  • The name of the head node is exported in the ClusterName attribute in the MetaData.xml file. Before you import the settings on a different head node, change this attribute so that it corresponds to the proper computer name.

Sample scenarios

The Export-HpcConfiguration.ps1 and Import-HpcConfiguration.ps1 scripts can help a cluster administrator perform one or more of the following tasks:

  • Backup and restore the head node computer

  • Migrate cluster configurations from the current head node computer to new hardware

  • Synchronize geographically distinct clusters

  • Mayntain a spare head node computer in a different location that can be brought into service to ensure business continuity in case of a disaster

Example: Synchronize geographically distinct clusters

A large financial services company Mayntains two Windows HPC Server 2008 R2 clusters in two cities, city A and city B. The clusters and the cluster users in these cities are members of the same Active Directory doMayn. Users in the cities run jobs and tasks by using the same service-oriented architecture (SOA) applications on each cluster, but the cluster nodes, job queue, and HPC databases are distinct.

From time-to-time, the IT department of the company rolls out a new SOA application for the clusters, first in city A, and then in city B. Although the SOA service DLLs must be deployed separately to the nodes on each cluster, the SOA service configuration files and management settings can be exported from the cluster in city A, and then imported to the cluster in city B. To do this, the cluster administrator in city A runs the Export-HpcConfiguration.ps1 with parameters similar to the following:

Export-HpcConfiguration.ps1 -Path C:\Path\ -Configuration Management,Scheduler,Soa

To synchronize the SOA service configuration files, the cluster administrator in city B runs Import-HpcConfiguration.ps1 with similar parameters.

Because the cluster configurations are synchronized, if a head node hardware failure or other disaster occurs in city A, users of the cluster in city A can quickly start using the applications on the cluster in city B. To submit jobs on the cluster in city B, users only need to change the name of the cluster in their SOA client applications or in the HPC client utilities.

Additional references