Creating a group in the sqlhosts file

You can define a group and the members of the group by adding entries to the sqlhosts file.

To create a database server group in the sqlhosts file:

  1. Add an entry to define the database server group:
    dbservername
    The name of the group. The name must begin with a lowercase letter, and can contain lowercase letters, numbers, and underscore (_) symbols.
    nettype
    The word group.
    hostname
    A dash (-) character (ASCII 45), to indicate that the field value is null.
    servicename
    A dash (-) character (ASCII 45), to indicate that the field value is null.
    options
    The c, e, or i options, as appropriate.
  2. Add one or more entries for members of the group. Include the g=group option.

Example

The following example shows definition of a group named g_asia. The group contains four members.

#dbservername  nettype   hostname  servicename  options
g_asia         group     –         –            c=1,e=manilla
tokyo          onsoctcp  node_1    service_1    g=g_asia
beijing        onsoctcp  node_2    service_2    g=g_asia
seoul          onsoctcp  node_3    service_4    g=g_asia
manilla        onsoctcp  node_4    service_5    g=g_asia