Modifying a Grid

TimesTen Scaleout defines several different types of objects in the model to give shape to a grid.

  • Data space groups

  • Hosts

  • Installations

  • Instances

Additionally, there are two types of model objects that describe the databases that the grid manages and that, in conjunction, define the names by which you connect to these databases. These types of objects are:

  • Database definitions

  • Connectables

Note:

See Central Configuration of the Grid for a complete list of the types of model objects and their descriptions.

You can create, modify, or delete objects in the model. Consider that changes you make to the model only take effect after you apply them to the current version of the model.

Note:

The following topics describe how to modify or delete the objects that give shape to a grid:

Modifying the Settings of a Grid

You can modify any of the following settings at any time after the creation of a grid.

Modifying Objects in a Grid

Of the objects in the model that give shape to a grid, only hosts and instances can be modified. Installations can only be deleted. These topics describe how to modify the attributes of the hosts and instances in a grid:

Modify a Host

You can modify certain attributes of a host with ttGridAdmin hostModify command. The name and communication parameters (internal or external DNS names or IP addresses) of a host cannot be modified. Once you assign a host to a data space group and apply that assignment to the current version of the model, you cannot change it.

For more information on the ttGridAdmin hostModify command, see Modify a Host (hostModify) in Oracle TimesTen In-Memory Database Reference.

Modify an Instance

You can modify the installation associated with an instance with ttGridAdmin instanceModify command. Also, this command enables you to modify the TCP/IP port number of the replication agent of a management instance, but only if there is not a second management instance available. In other words, you can only modify the TCP/IP port number of the replication agent of a management instance if the port is not in use. See Upgrade a Grid to a Patch-Compatible Release for an example where several instances are modified.

For more information on the ttGridAdmin instanceModify command, see Modify an Instance (instanceModify) in Oracle TimesTen In-Memory Database Reference.

Deleting Objects from a Grid

These topics describes how to delete objects from a grid:

Delete a Data Instance

Before you can delete a data instance from a grid, you need to remove the element of the data instance from the distribution map of every database, as shown next:

  1. Remove the element of the data instance from the distribution map of every database as shown in Removing Elements from the Distribution Map.
  2. Delete the data instance from the latest version of the model.
    % ttGridAdmin instanceDelete host6.instance1
    Instance instance1 on Host host6 deleted from Model
  3. Apply the changes made to the latest version of the model.
    % ttGridAdmin modelApply
    ...
    Identifying any deleted objects.......................................OK
    Stopping deleted instances............................................OK
    Deleting instances....................................................OK
    ...
    ttGridAdmin modelApply complete

For more information on the ttGridAdmin instanceDelete command, see Delete an Instance (instanceDelete) in Oracle TimesTen In-Memory Database Reference.

For more information on the ttGridAdmin modelApply command, see Applying the Changes Made to the Model and Model Operations in Oracle TimesTen In-Memory Database Reference.

Delete a Management Instance

Only the standby management instance can be deleted from a grid. If you intend to delete the active management instance in a grid with two management instances, first switch the standby management instance to active with the ttGridAdmin mgmtActiveSwitch command, then proceed.

Note:

For availability, we highly recommend that you always have an active and a standby management instance in your grid. Only delete the standby management instance if you intend to replace it with another one as soon as possible.

If you intend to delete the active management instance in a grid with only one management instance, consider destroying the grid in a graceful manner. See Destroying a Grid.

To delete the standby management instance from a grid, perform these tasks:

  1. Confirm that the instance you want to delete is the standby management instance.
    % ttGridAdmin mgmtStatus
    Host  Instance  Reachable RepRole(Self) Role(Active) Role(Self) Seq RepAgent RepActive Message 
    ----- --------- --------- ------------- ------------ ---------- --- -------- --------- ------- 
    host1 instance1 Yes       Active        Unknown      Active     338 Up       Yes 
    host2 instance1 Yes       Standby       Unknown      Standby    338 Up       No
  2. Delete the standby management instance from the latest version of the model.
    % ttGridAdmin instanceDelete host2.instance1
    Instance instance1 on Host host2 deleted from Model
  3. Apply the changes made to the latest version of the model.
    % ttGridAdmin modelApply
    ...
    Unconfiguring standby management instance.............................OK
    Identifying any deleted objects.......................................OK
    Stopping deleted instances............................................OK
    Deleting instances....................................................OK
    ...
    ttGridAdmin modelApply complete

For more information on the ttGridAdmin mgmtActiveSwitch command, see Starting, Stopping and Switching Management Instances and Switch the Active Management Instance (mgmtActiveSwitch) in Oracle TimesTen In-Memory Database Reference.

For more information on the ttGridAdmin instanceDelete command, see Delete an Instance (instanceDelete) in Oracle TimesTen In-Memory Database Reference.

For more information on the ttGridAdmin modelApply command, see Applying the Changes Made to the Model and Model Operations in Oracle TimesTen In-Memory Database Reference.

Delete an Installation

You may want to delete an installation if you just performed an upgrade operation to a new release of TimesTen Scaleout. Deleting an installation does not remove the installation files, since the files may be still in use if the location of the files is shared by other installations in this or any other grid. See Upgrade a Grid to a Patch-Compatible Release for more information on upgrade and cleanup operations, which includes deleting the previous release installation model object and files.

However, if you are deleting an installation because you are removing its associated host from the topology of the grid, see Delete a Host for details on how to delete a host and its associated objects, which includes the installation model object and files.

Delete a Host

Before you can delete a host from a grid, you must ensure that other model objects associated with the host are not in use, as shown next:

  1. Remove the element of every data instance associated with the host from the distribution map of every database, as shown in Removing Elements from the Distribution Map.

  2. Delete every instance and installation associated with the host, and then, delete the host from the latest version of the model. You can either delete each object separately or use the -cascade of option of the ttGridAdmin hostDelete command to delete the host and every instance and installation associated with it.

    1. Delete a host and all its associated objects separately

      % ttGridAdmin instanceDelete host6.instance1
      Instance instance1 on Host host6 deleted from Model
      
      % ttGridAdmin installationDelete host6.installation1
      Installation installation1 on Host host6 deleted from Model
      
      % ttGridAdmin hostDelete host6
      Host host6 deleted from Model
    2. Delete a host and all its associated objects

      % ttGridAdmin hostDelete host6 -cascade
      Instance instance1 on Host host6 deleted from Model
      Installation installation1 on Host host6 deleted from Model
      Host host6 deleted from Model
  3. Apply the changes made to the latest version of the model.

    % ttGridAdmin modelApply
    ...
    Identifying any deleted objects.......................................OK
    Stopping deleted instances............................................OK
    Deleting instances....................................................OK
    Deleting installations from model.....................................OK
    Deleting any hosts that are no longer in use..........................OK
    ...
    ttGridAdmin modelApply complete
  4. If the installation files associated with the installation model objects you just deleted are not in use by any other installation object in this or any other grid, then delete the files. Ensure that you change the permissions of the directory so that you can delete all files.

    % cd /grid
    % chmod -R 750 tt22.1.1.18.0/
    % rm -rf tt22.1.1.18.0/

For more information on the ttGridAdmin instanceDelete, ttGridAdmin installationDelete, or ttGridAdmin hostDelete command, see Delete an Instance (instanceDelete), Delete an Installation (installationDelete), or Delete a Host (hostDelete), respectively, in Oracle TimesTen In-Memory Database Reference.

For more information on the ttGridAdmin modelApply command, see Applying the Changes Made to the Model and Model Operations in Oracle TimesTen In-Memory Database Reference.

Reconfiguring Membership Servers

These topics describe how to view and modify your current membership configuration:

For more information on membership servers, see the Apache ZooKeer website.

View the Current Membership Configuration

To view your current membership configuration, run the ttGridAdmin membershipConfigExport command. This lists the membership servers and the ports used.

% ttGridAdmin membershipConfigExport
Servers ms_host1!2181,ms_host2!2181,ms_host3!2181

For more information on the ttGridAdmin membershipConfigExport command, see Export the Membership Configuration File (membershipConfigExport) in Oracle TimesTen In-Memory Database Reference.

Add Membership Servers

You can add a new server to the list of membership servers to reflect your desired membership configuration. To add the ms_host4 server and its client port 2181:

  1. Create a new server configuration file, for example, membership2.conf. For more information on the ZooKeeper client configuration file, see Configuring Apache ZooKeeper as the Membership Service.
  2. Append the new membership server and port to the current list of membership servers.
    Servers ms_host1!2181,ms_host2!2181,ms_host3!2181,ms_host4!2181

Enable the New Membership Configuration

To enable your new membership configuration, perform these tasks:

  1. Replace the ZooKeeper client configuration file in the latest version of the model with the newly created file.
    % ttGridAdmin membershipConfigImport membership2.conf
    Membership configuration file membership2.conf imported
  2. Run the ttGridAdmin modelApply command to apply the changes to the latest version of the model.
    % ttGridAdmin modelApply
    Creating new model version............................................OK
    Exporting current model (version 3)...................................OK
    Identifying any changed management instances..........................OK
    Identifying any deleted objects.......................................OK
    Verifying installations...............................................OK
    Verifying instances...................................................OK
    Updating grid state...................................................OK
    Pushing new configuration files to each instance......................OK
    Making model version 3 current, version 4 writable....................OK
    ttGridAdmin modelApply complete
  3. Stop and restart every instance in the grid. For more information on stopping and restarting a grid, see Stopping a Grid and Restarting a Grid, respectively.

For more information on the ttGridAdmin membershipConfigImport command, see Import the Membership Configuration File (membershipConfigImport) in Oracle TimesTen In-Memory Database Reference.

For more information on the ttGridAdmin modelApply command, see Applying the Changes Made to the Model and Model Operations in Oracle TimesTen In-Memory Database Reference.