Sun Cluster Data Service for Informix Guide for Solaris OS

Chapter 1 Installing and Configuring Sun Cluster HA for Informix

This chapter explains how to install and configure the Sun Cluster HA for Informix data service.

This chapter contains the following sections:

Overview of the Installation and Configuration Process for Sun Cluster HA for Informix

The table below lists the tasks for installing and configuring Sun Cluster HA for Informix. Perform these tasks in the order that they are listed.

Table 1–1 Installing and Configuring Sun Cluster HA for Informix

Task

Instruction

Plan the Informix installation 

Planning the Sun Cluster HA for Informix Installation and Configuration

Prepare the nodes and disks for Informix installation 

Preparing the Nodes and Disks

Install and configure Informix 

Installing and Configuring Informix

Enable the Informix instances to run in a cluster 

Enabling the Informix Instances to Run in a Cluster

Install Sun Cluster HA for Informix packages 

Installing the Sun Cluster HA for Informix Packages

Register and configure Sun Cluster HA for Informix 

Registering and Configuring Sun Cluster HA for Informix

Verify Sun Cluster HA for Informix installation and configuration 

Verifying the Sun Cluster HA for Informix Installation and Configuration

Understand the Sun Cluster HA for Informix Fault monitor 

Understanding the Sun Cluster HA for Informix Fault Monitor

Debug Sun Cluster HA for Informix 

Debugging Sun Cluster HA for Informix

Planning the Sun Cluster HA for Informix Installation and Configuration

This section contains the information you need to plan your Sun Cluster HA for Informix installation and configuration.


Note –

Sun Cluster HA for Informix can be configured to run in a whole root or a sparse root non-global zone, if required.


Configuration Restrictions

This section provides a list of software and hardware configuration restrictions that apply to Sun Cluster HA for Informix. Use the restrictions in this section to plan the installation and configuration of Sun Cluster HA for Informix.


Caution – Caution –

Your data service configuration might not be supported if you do not observe these restrictions.


For restrictions that apply to all data services, see the Sun Cluster Release Notes for Solaris OS.

Restriction for Supported Configurations of Sun Cluster HA for Informix

Sun Cluster HA for Informix data service can be configured only as a failover service. Single or multiple instances of Informix Dynamic Server can be deployed in the cluster. Informix Dynamic Server can be deployed in the global zone or non-global zone.

Restriction for the Location of Informix Files

You need to keep these restrictions in mind while planning the installation and configuration of Sun Cluster HA for Informix.

Configuration Requirements

Use the requirements in this section to plan the installation and configuration of Sun Cluster HA for Informix. These requirements apply only to Sun Cluster HA for Informix. You must meet these requirements before you proceed with your Sun Cluster HA for Informix installation and configuration.


Caution – Caution –

Your data service configuration might not be supported if you do not adhere to these requirements.


For requirements that apply to all data services, see “Configuration Guidelines for Sun Cluster Data Services” in Sun Cluster Data Services Planning and Administration Guide for Solaris OS.

Determine the Solaris Zone for Informix Dynamic Server to Use

Solaris zones provides a means of creating virtualized operating system environments within an instance of the Solaris 10 OS. Solaris zones enable one or more applications to run in isolation from other activity on your system. For complete information about installing and configuring a Solaris Container, refer to System Administration Guide: Solaris Containers-Resource Management and Solaris Zones.

You must determine which Solaris zone Informix Dynamic Server will use. Informix Dynamic Server can be deployed in the global zone or non-global zone.

Preparing the Nodes and Disks

Use the files source for the passwd, group, and project database entries in the /etc/nsswitch.conf file and do not use external sources such as NIS, NIS+, or LDAP for the passwd, group, and project database entries.

Sun Cluster HA for Informix uses the su command to start, stop, and probe the Informix application and might be impacted if an external name service is unavailable.

On each node or zone that can master the Informix resource, include the following entries in the /etc/nsswitch.conf file.

passwd:  files
group:   files
project: files

However, you might still use an external name service such as NIS, NIS+, or LDAP. Remember, though, that if the external name service is unavailable, Sun Cluster HA for Informix might fail.

Installing and Configuring Informix

This section contains the procedures that you need to install and configure the Informix application.

ProcedureHow to Install Informix

Use this procedure to install the Informix application.

  1. On a cluster member, become superuser or assume a role that provides solaris.cluster.modify RBAC authorization.

  2. Create a cluster file system or highly available local file system for the Informix files.

    Refer to the Sun Cluster Software Installation Guide for Solaris OS for information about creating a cluster file system and the Sun Cluster Data Services Planning and Administration Guide for Solaris OS for information about creating a highly available local file system.

  3. Create an Informix user ID and group ID on all the nodes or zones of the cluster that can master the Informix Dynamic Server.

  4. Install Informix binaries on the cluster node or zone where the file system created in Step 2 is mounted.


    Note –

    For more information about how to install Informix, see .



    Note –

    Before you install Informix on a cluster file system, use the scstat(1M) command to verify that the Sun Cluster software is fully operational.


Enabling the Informix Instances to Run in a Cluster

This section contains the procedure that you need to verify the Informix installation.

ProcedureHow to Enable the Informix Instances to Run in a Cluster

Use this procedure to verify the Informix instance. Perform the following steps on a node or zone on which the Informix instance can run.

  1. Log in to the cluster node or zone on which you installed the Informix software.

  2. Shut down the Informix instance.

    For more information about how to start or stop Informix, see http://publib.boulder.ibm.com/infocenter/idshelp/v111/index.jsp

  3. Mount the highly available local file system if used.

  4. Create the failover resource group to hold the network and application resources.


    # clresourcegroup create ids-rg
    

    Note –

    Use the -n option to the clresourcegroup command to select the set of nodes or zones on which the Informix application can run.


    # clresourcegroup create ids-rg [-n node-zone-list]
    

  5. Verify that you have added to your name service database all the network resources that you use.

  6. Add a network resource (logical hostname) to the failover resource group.


    # clreslogicalhostname create -g ids-rg [-h lhost[,...]] [-d] ids-lh
    
  7. Edit the $INFORMIXDIR/etc/sqlhosts.$INFORMIXSERVER file and update the hostname to reflect the logical host.

  8. Add the HAStoragePlus resource to the resource group for the failover application.


    # clresource register SUNW.HAStoragePlus
    # clresource create -g ids-rg \
    -t SUNW.HAStoragePlus \
    -p filesystemmountpoints=mountpoint,... ids-has
    

    The resource is created in the enabled state.


    Tip –

    This HAStoragePlus resource is used for the $INFORMIXSERVER file.


    For more information on how to set up an HAStoragePlus resource, see “Enabling Highly Available Local File Systems” in Sun Cluster Data Services Planning and Administration Guide for Solaris OS.

  9. Enable the resource group.

    Run the clresourcegroup(1CL) command to move the resource group into a managed state and bring the resource group online.


    # clresourcegroup online -M ids-rg
    
  10. Start the Informix database on a node where the resource group is online.

    Ensure that the Informix database starts smoothly by connecting to the database by using the logical hostname.

  11. Shut down the Informix database.

  12. As user root, switch the Informix database resource group to another cluster member.


    # clresourcegroup switch -n node[:zone] ids-rg
    
  13. Start the Informix database.

    Ensure that the Informix database starts smoothly by connecting to the database by using the logical hostname.

  14. Ensure that you switch the Informix resource group to all the nodes in the resource group's nodelist and also ensure that you can start Informix on all the nodes of the cluster.

Installing the Sun Cluster HA for Informix Packages

If you did not install the Sun Cluster HA for Informix packages during your initial Sun Cluster installation, perform this procedure to install the packages. To install the packages, use the Sun JavaTM Enterprise System Installation Wizard.


Note –

You need to install the Sun Cluster HA for Informix packages in the global cluster and not in the zone cluster.


ProcedureHow to Install the Sun Cluster HA for Informix Packages

Perform this procedure on each cluster node where you are installing the Sun Cluster HA for Informix packages.

You can run the Sun Java Enterprise System Installation Wizard with a command-line interface (CLI) or with a graphical user interface (GUI). The content and sequence of instructions in the CLI and the GUI are similar.


Note –

Even if you plan to configure this data service to run in non-global zones, install the packages for this data service in the global zone. The packages are propagated to any existing non-global zones and to any non-global zones that are created after you install the packages.


Before You Begin

Ensure that you have the Sun Java Availability Suite DVD-ROM.

If you intend to run the Sun Java Enterprise System Installation Wizard with a GUI, ensure that your DISPLAY environment variable is set.

  1. On the cluster node where you are installing the data service packages, become superuser.

  2. Load the Sun Java Availability Suite DVD-ROM into the DVD-ROM drive.

    If the Volume Management daemon vold(1M) is running and configured to manage DVD-ROM devices, the daemon automatically mounts the DVD-ROM on the cdrom directory.

  3. Change to the Sun Java Enterprise System Installation Wizard directory of the DVD-ROM.

    • If you are installing the data service packages on the SPARC® platform, type the following command:


      # cd /cdrom/cdrom0/Solaris_sparc
      
    • If you are installing the data service packages on the x86 platform, type the following command:


      # cd /cdrom/cdrom0/Solaris_x86
      
  4. Start the Sun Java Enterprise System Installation Wizard.


    # ./installer
    
  5. When you are prompted, accept the license agreement.

    If any Sun Java Enterprise System components are installed, you are prompted to select whether to upgrade the components or install new software.

  6. From the list of Sun Cluster agents under Availability Services, select the data service for Informix.

  7. If you require support for languages other than English, select the option to install multilingual packages.

    English language support is always installed.

  8. When prompted whether to configure the data service now or later, choose Configure Later.

    Choose Configure Later to perform the configuration after the installation.

  9. Follow the instructions on the screen to install the data service packages on the node.

    The Sun Java Enterprise System Installation Wizard displays the status of the installation. When the installation is complete, the wizard displays an installation summary and the installation logs.

  10. (GUI only) If you do not want to register the product and receive product updates, deselect the Product Registration option.

    The Product Registration option is not available with the CLI. If you are running the Sun Java Enterprise System Installation Wizard with the CLI, omit this step.

  11. Exit the Sun Java Enterprise System Installation Wizard.

  12. Unload the Sun Java Availability Suite DVD-ROM from the DVD-ROM drive.

    1. To ensure that the DVD-ROM is not being used, change to a directory that does not reside on the DVD-ROM.

    2. Eject the DVD-ROM.


      # eject cdrom
      
Next Steps

Go to Registering and Configuring Sun Cluster HA for Informix.

Registering and Configuring Sun Cluster HA for Informix

This section contains the procedures you need to configure Sun Cluster HA for Informix.

ProcedureHow to Register and Configure Sun Cluster HA for Informix

Use this procedure to configure Sun Cluster HA for Informix.

  1. Become superuser on one of the nodes or zones in the cluster that hosts the Informix database resource group.

  2. Edit the /opt/SUNWscids/util/ids_config file and type values as required by following the comments within the file.


    RS=ids-rs
    RG=ids-rg
    LH_RS=ids-lh
    HAS_RS=ids-has
    USERID=informix
    ONCONFIG=onconfig.demo_on
    INFORMIXDIR=/opt/IBM/informix
    INFORMIXSERVER=demo_on
    INFORMIXSQLHOSTS=/opt/IBM/informix/etc/sqlhosts.demo_on
    
  3. Register the resource type for the failover application.


    # clresourcetype register SUNW.gds.
    
  4. Register the Informix resource.


    # cd /opt/SUNWscids/util
    # ./ids_register
    

Verifying the Sun Cluster HA for Informix Installation and Configuration

This section contains the procedure you need to verify that you installed and configured your data service correctly.

ProcedureHow to Verify Installation and Configuration of Sun Cluster HA for Informix

Use this procedure to verify the installation and configuration of Sun Cluster HA for Informix.

  1. Log in to the node or zone that currently hosts the resource group that contains the Informix application resource.

  2. As user root, switch the Informix resource group to another cluster member.


    # clresourcegroup switch -n node[:zone] ids-rg
    
  3. Verify that the Informix application starts on the node or zone that you specified in Step 1.

  4. Repeat Step 1 through Step 3 until you have tested all the potential nodes or zones on which the Informix application can run.

Understanding the Sun Cluster HA for Informix Fault Monitor

This section describes the Sun Cluster HA for Informix fault-monitor probing algorithm or functionality.

For conceptual information about fault monitors, see the Sun Cluster Concepts Guide.

Probing Algorithm and Functionality

Sun Cluster HA for Informix fault monitor is controlled by the extension properties that control the probing frequency. The default values of these properties determine the preset behavior of the fault monitor. The preset behavior should be suitable for most Sun Cluster installations. Therefore, you should tune the Sun Cluster HA for Informix fault monitor only if you need to modify this preset behavior. You can modify this behavior by performing the following actions:

The Sun Cluster HA for Informix fault monitor checks the database within an infinite loop. During each cycle the fault monitor checks the database state and reports either a failure or success.

If the fault monitor is successful, it returns to its infinite loop and continues the next cycle of probing and sleeping.

If the fault monitor reports a failure, a request is made to the cluster to restart the resource. If the fault monitor reports another failure, another request is made to the cluster to restart the resource. This behavior continues whenever the fault monitor reports a failure.

If successive restarts exceed the Retry_count within the Thorough_probe_interval, a request is made to fail over the resource group onto a different node or zone.

Operations of the Informix Probe

The Informix probe checks the database state by using the onstat command.

The onstat - command produces a status line for the database server. The status line is accurate at the instant that the command executes and identifies the server and version but more importantly, the status of the database server.

The status modes that are considered to be normal operational modes are On-Line and Read-only. Whenever the onstat command reports these status modes, the Informix probe considers that the database server is operating in an acceptable mode.

The status modes that are considered to be maintenance and startup modes are Quiescent, Administration, Single User, Initialization, Fast Recovery, and Recovery. While the database server is starting, the probe considers these modes acceptable. However, after the database has started successfully, these modes are not considered acceptable and if one of these modes is encountered, the probe requests a restart of the resource.

The probe also requests a resource to restart if any unknown status modes are reported by the onstat command.

Debugging Sun Cluster HA for Informix

ProcedureHow to Turn on Debugging for Sun Cluster HA for Informix

Sun Cluster HA for Informix can be used by multiple Informix instances. Debugging can be turned on for all Informix instances or a particular Informix instance.

The /opt/SUNWscids/etc/config file enables you to turn on debugging for all Informix instances or for a specific Informix instance on a particular node or zone within the cluster. If you require debugging to be turned on for Sun Cluster HA for Informix across the whole cluster, repeat this step on all nodes within the cluster.

  1. Edit the /etc/syslog.conf file and change daemon.notice to daemon.debug.


    # grep daemon /etc/syslog.conf
    *.err;kern.debug;daemon.notice;mail.crit        /var/adm/messages
    *.alert;kern.err;daemon.err                     operator
    #

    Change the daemon.notice file to daemon.debug and restart the syslogd command. Note that the following output, from grep daemon /etc/syslog.conf, shows that daemon.debug has been set.


    # grep daemon /etc/syslog.conf
    *.err;kern.debug;daemon.debug;mail.crit        /var/adm/messages
    *.alert;kern.err;daemon.err                    operator

    Restart the syslog daemon.

    • If you are running Solaris 10, type:


      # svcadm disable system-log
      # svcadm enable system-log
      
  2. Edit the /opt/SUNWscids/etc/config file.

    Perform this step for each component that requires debugging output, on each node of Sun Cluster as required.

    Edit the /opt/SUNWscids/etc/config file and change DEBUG= to DEBUG=ALL or DEBUG=sun-cluster-resource.


    # cat /opt/SUNWscids/etc/config
    #
    # Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
    # Use is subject to license terms.
    #
    # ident "@(#)config     1.1     06/03/06 SMI"
    #
    # Usage:
    #       DEBUG=<RESOURCE_NAME> or ALL
    #
    DEBUG=ALL

    Note –

    To turn off debug, reverse the previous steps.