setmaster

Sets a subordinate metadata server as the new master metadata server in the event of an irrecoverable loss of the current master metadata server.

Read syntax diagramSkip visual syntax diagram
>>-setmaster--+----------+--server_name------------------------><
              +- –?----+
              +- –h----+
              '- –help-'

Parameters

–? | –h | –help
Displays a detailed description of this command, including syntax, parameter descriptions, and examples. If you specify a help option, all other command options are ignored.
server_name
Specifies the name of the subordinate metadata server to set as the master metadata server.

Prerequisites

You must have Administrator privileges to use the command.

You must be logged in to the operating system on the engine hosting the subordinate metadata server to run this command.

Description

Attention: This command is not available in SAN File System version 2.1. It is available only during a rolling upgrade from SAN File System version 1.1 to version 2.1.
Attention: When you invoke the setmaster command, applications will notice a pause in service, which could adversely affect application that are sensitive to time outs.
Attention: If the master metadata server is not shut down, you could destroy all of your data. Before using the setmaster command, perform the following steps to verify that the master metadata server is not shut down:
  1. From the engine hosting the master metadata server, perform the following steps:
    1. Verify that the master metadata server is offline by invoking the lsserver command.
    2. If the master metadata server is online, invoke the stopserver command to stop the master metadata server.

      Do not stop the subordinate metadata servers.

    3. Verify again that the master metadata server is offline by invoking the lsserver and statcluster –netconfig commands.
  2. Verify that all other metadata servers are subordinates by invoking the lsserver command from each engine hosting the remaining metadata servers.
  3. From the engine hosting the subordinate metadata server that you want to become the master, perform the following steps:
    1. Verify that the engine hosting the master metadata server is shut down by invoking the lsengine command.
      If the engine is running, use the stopengine or stopengine –f command to shut it down.
      Note: If you cannot shut down the engine remotely or through the Administrative CLI, manually power off the engine.
    2. Verify again that the engine hosting the master metadata server is shut down by invoking the lsengine command.

Before stopping the master metadata server, you should move the filesets that are being served by the master metadata server to another metadata server.

Setting a new master metadata server may affects the clients. If the clients mount to the global namespace using the IP address of the master metadata server, this address will become unavailable if the client reboots. Therefore, you must reset the IP address to which each client mounts. For AIX® client, edit the /usr/tank/client/config/stclient.conf file, and set the server_hot_name variable.

The setmaster command demotes the master metadata server to a subordinate. It does not drop the metadata server from the cluster. When you restart the engine, the metadata server joins the cluster as subordinate.

This command is useful when you want to replace hardware components of or upgrade the engine hosting the master metadata server.

Example

Set the master metadata server The following example verifies that the master metadata server ST0 is shut down and then sets the subordinate metadata server ST1 as the master metadata server.

From metadata server ST0:
sfscli> lsserver
Name  State   Server Role  Filesets  Last Boot
==============================================================
ST0   Online  Master                0  Jul 10, 2003 7:00:17 AM
ST1   Online  Subordinate           2  Jul 10, 2003 7:00:24 AM

sfscli> stopservre ST0
Server "ST0" stopped gracefully.

sfscli> lsserver
Name  State        Server Role  Filesets  Last Boot
===================================================================
ST0   Not Running  Master                -  -
ST1   Joining      Subordinate           2  Jul 10, 2003 7:00:24 AM

sfscli> statcluster -netconfig
Could not connect to the server. Please start the server.
From metadata server ST1:
sfscli> lsserver
Name  State    Server Role  Filesets  Last Boot
===============================================================
ST1   Joining  Subordinate           2  Jul 10, 2003 7:00:24 AM

sfscli> statcluster -netconfig
statcluster must be issued from the admin master server.

sfscli> stopengine ST0
Are you sure you want to stop engine "ST0"? [y/n]  Y
Engine "ST0" was shutdown successfully.

sfscli> lsengine
Name  Engine IP      Boot State         Temp    Fans    Voltage
===============================================================
ST1   555.168.10.25  In OS              Normal  Normal  Normal
ST0   555.168.10.24  Unknown/Power Off  -       -       -

sfscli> setmaster ST1
Server "ST1" is the new master server.

sfscli> lsserver
Name  State    Server Role  Filesets  Last Boot
===============================================================
ST1   Online   Master                2  Jul 10, 2003 7:05:12 AM
ST0   Unknown  Subordinate           2  Jul 10, 2003 7:05:12 AM

Parent topic: Administrative commands

Terms of use | Feedback
(C) Copyright IBM Corporation 2003, 2004. All Rights Reserved.