Back

BSUtils Database Groups

All BSUtils tools connect to Oracle databases remotely using Oracle Database client and Oracle Net (even to databases running on the same machine as the BSUtils tool). Databases are identified to the client by net service names defined, typically, in a network configuration file tnsnames.ora.

BSUtils database groups are persistent named lists of database net service names (for simplicity called "databases" or "database names" here) that you create to specify as targets for MuSQL or PassAid to execute a similar instruction (that is, to run a SQL script or change an account's password) in each database in the list. A database group can also include references to other database groups (so called "nested" groups).

In your database groups, you can group databases in any way you want - based on a line of business (e.g. HR, Sales, Customer A's databases, etc.), on server environment (Unix, Windows, hosted in Dallas), life cycle stage (Development, Test, Production), other features (pre-9i, RAC, standby), alphabetically (names beginning from A to M, from N to Z), etc. Each database can be a member of multiple groups.

If you have many databases and often need to group them differenlty for particular tasks, you may want to begin with creating smaller, "basic" groups of databases that are almost always are processed together, and then combine these basic groups into various bigger groups using group nesting.

Database names and nested group names are listed in a group one name per line. Names are not: case-sensitive. A nested group's name must be preceded by character @, like in this example:

SALES_DB1
SALES2
@Test_Databases

Database groups can have comments. You can use comments as database section headers or to temporarily comment out some databases. The comment character is #. On any line, everything following a # is considered a comment. If a database name is followed by a comment on the same line, there must be at least one space between them.

You can use one of two methods to create or edit a database group. You can select names from a full list of databases in your current network configuration file tnsnames.ora, or you can use Notepad file editor to type database names. In the latter case, when you create a new group, you can have the new file to be pre-populated with a full list of database names from the current tnsnames.ora file. Database Groups menu has an option to change the group editing method, Using the application's Defaults menu, you can save the current group editing method as the default for future sessions.

Each method has its advantages and drawbacks. When selecting from a list, you select from all names of the databases in the current tnsnames.ora file, but not from names resolved through other naming methods, such as names directory. You don't have to type anything, just select from a list, so you will not make typing errors. However, the process can be slow when the full list is long, and you cannot use comments. Typing database names in a Notepad session can be as fast as you can type; you can copy, cut and paste; you can print out the group content and you can use comments, but you can also make typing errors (although the entered names are checked against the current tnsnames.ora file after the Notepad window is closed.)

When a new group is being created by typing in a Notepad session, the new group is temporarily named New Group1. When finished, save the group and close Notepad. Do not use the "Save As" command - you will be given an opportunity to rename the new group after Notepad editing session is closed. After that, all names in the saved group will be checked against the current tnsnames.ora file.

Typically, when MuSQL job is executed or PassAid proceeds with password changes, connection with the same user ID and password is attempted to all databases in the group. Therefore, generally, a group should not include databases for which you are certain the account passwords are different, as connection attempts with a wrong password may lead to account lockout. Note that normal connections (not "as sysdba") to physical standby databases may not be possible; you may want not to include (or comment out) names of such databases in a group that has active (primary) databases.

Database groups can be exported and imported. This is useful when you want to recreate the same groups on another machine. A command-line utility capable of creating and extracting zip archive files (zip.exe and unzip.exe from Info-ZIP or pkzipc.exe from PKWARE) must be available in order to export and import database groups.

Back