IBM Support

SVC Configuration Backup to the Master Console

Troubleshooting


Problem

This topic illustrates how to create and retrieve cluster configuration back-up files to the SVC Master Console for archiving, and how "Scheduled Tasks" can be used to automate such retrieval on a regular basis.

Resolving The Problem



Introduction

SVCCONFIG is a command line tool that can be used to back-up and restore the configuration of a cluster. When used for back-up, it generates a file "svc.config.backup.xml" in "/tmp" on the node of the cluster upon which the command is executed.

It is desirable to copy this file off-cluster for archiving. This topic shows how to perform back-up from the Master Console using the SVCRCONFIG sample program, so that the back-up file is moved off-cluster after it has been generated. The sample program can be run manually, or as a "Scheduled Task".



Pre-requisites

SAN Volume Controller 1.1.1 or later
Master Console any version, with


    CSCRIPT (a small VBScript program supports the main BAT program)
    PLINK (secure command execution on the SVC)
    PSCP (secure file transfer from the SVC)

Download instructions

Create a directory "\temp\svcrconfig" on the Master Console and download the sample program files to it:


Preparing the cluster for secure communications

Firstly, ensure that the Master Console can communicate with the cluster, in order to execute commands.

You will need a private/public key pair that can be used with pageant.exe to communicate with the cluster. Only keys generated using puttygen.exe can be used with pageant.exe. You may have a suitable key pair already, or you may need to use puttygen.exe now:




Click on "Generate" and follow the instructions to generate a key pair. After generating the key pair, click on "Save public key" and save the key as "svcrconfig.key.pub".

Click on "Save private key" and type in "svcrconfig" as the file name.


After using puttygen.exe, you will have the following files:


    svcrconfig.key.pub
    svcrconfig.PPK

Follow the instructions in the section called 'Maintaining SSH Keys' in the SVC Software Installation & Configuration Guide to upload the public key to the SVC cluster.

Preparing the Master Console for secure communications

Run pageant.exe. This places an icon in the System Tray. Right-click on the "pageant" icon (the last one in this screen shot), and select "Add Key".

Then select the private key and click on "Open".


The program syntax






 
Parameters:
 
backup
Backs up a cluster configuration, and creates configuration files
on the Master Console. All files are prefixed with today's date.
 
clear
Clears existing configuration back-up files (only) from the Master
Console. Clears all such files in the path (see below).
 
list
Lists configuration back-up files (only) on the Master Console.
 
-path path
Identifies an off-cluster directory in which one or more configuration
files are maintained. It can be either fully- or relatively-qualified,
and must be accessible for both reading and writing files. path may
not contain embedded blanks, although if relative it may reference a
fully-qualified directory that does contain embedded blanks. The
default is the current directory.
 
object
The IP address of a cluster. This is communicated with using secure
communications.

Error messages

The SVCRCONFIG Sample Program issues some of the same messages that the SVCCONFIG command issues, but also has a few additional ones:

Number
Message
Description
CMMVC6166E The argument (value) is not valid The argument to the program is not recognized. Remove it and try again.
CMMVC6167E Directory (path) does not exist The directory must exist. Change the reference to an existing directory, and try again.
CMMVC6168I Executing (command) The program is executing the indicated command on the remote cluster.



Running the program manually

Create a directory to contain the retrieved configuration back-up files. The default is the current directory, but "\temp\svcrconfig" is used in this topic. A cluster IP address is required, and "svccluster" is used in this topic.

Run "svcrconfig backup svccluster –path \temp\svcrconfig".

This is the console output:





Note that, as the first remote command is executed, "PuTTY" requires a confirmation regarding secure access. If you reply "n", then "PuTTY" will repeat the request for every remote command that is run. If you reply "y", then "PuTTY" will make a permanent note of your confirmation and not bother you again, as in the above example.

As you can see, 3 remote commands are run. The 1st performs the back-up, which places output in "/tmp" on the cluster. The messages you receive, if any, will vary depending upon your cluster configuration. The 2nd command transfers all output from the cluster to "\temp\svcrconfig" on the Master Console. A wild-card is used in the transfer, and that requires the use of the "-unsafe" option with pscp.exe. The 3rd command clears the files in "/tmp" now that they have been moved off-cluster.

To see what files have been produced, run "svcrconfig list –path \temp\svcrconfig". The file-names are prefixed with today's date. The format of the prefix may vary depending on your locale.

The sample program can be run on different dates without affecting the results from previous dates. However, note that "svcrconfig clear –path \temp\svcrconfig" will clear back-up files for all dates.



Running the program on a regular basis

We will now use the "Scheduled Tasks" facility of the operating system to automate the running of the sample program.

This automation has its short-comings, because pageant.exe needs to be running, and needs to have the relevant private key loaded. Ideally this requires a configurable service. As it is, you will need to start pageant.exe and load the private key as described earlier, and remain logged on while the scheduled task runs. If pageant.exe is not running, then the scheduled task will run, but will fail because it cannot communicate with the remote cluster.






Click on the "Start" menu, and select "Programs", "Accessories", "System Tools" and "Scheduled Tasks"

Open "Add Scheduled Task" to start the Scheduled Task Wizard. Click on "Next" and then "Browse" for svcrconfig.bat and open it.






Type in a suitable name for the task and, for the time being, select "One time only".


On the next panel, select a time a little ahead of the present.




On the next panel, confirm the Master Console machine and user name that will be used to run the scheduled task. Do not bother to set the password yet.


On the next panel, select "Open advanced properties ..." before clicking on "Finish".


Add the arguments "backup svccluster" to the "Run" section:




Click on "Set password" to enter the password for the Master Console user under whose authority the task will run, then return to the panel above and click on "OK".

Now the new task is listed:




If you wait for the task to run, then a new console window will appear while it does so. However, you do not need to wait. You can disconnect and the task will still run. Remember that you cannot log off because that will stop pageant.exe.



Next steps

After this trial run, you can amend the task to run daily or less frequently. Generated files will have a name which begins with the day's date, and so the command is good for running daily or less frequently. If you run the same command more frequently though, the newer runs will overwrite files written earlier the same day. If the capabilities of the sample program do not meet your needs, you can customize it, or write a more capable program in another programming language.

[{"Product":{"code":"STPVGU","label":"SAN Volume Controller"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"V5.1.x","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Not Applicable","Edition":"","Line of Business":{"code":"LOB26","label":"Storage"}},{"Product":{"code":"STPVGU","label":"SAN Volume Controller"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"V4.2.x","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Version Independent","Edition":"","Line of Business":{"code":"LOB26","label":"Storage"}},{"Product":{"code":"STPVGU","label":"SAN Volume Controller"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"V4.3.x","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"Version Independent","Edition":"","Line of Business":{"code":"LOB26","label":"Storage"}}]

Document Information

Modified date:
17 June 2018

UID

ssg1S1002175