In this section we will cover the creation of a new Dbvisit Standby Configuration, also known as creating a Dbvisit Database Configuration (DDC) file.
Once you have done a clean installation of Dbvisit Standby, the first step is to create a configuration file or DDC, which will contain information about your environment as well as your Primary and Standby database settings.
For each Primary and Standby database pair there will be one DDC file. The file is created and maintained from the Primary server. The DDC file on the standby server is a mirrored copy of the one on the primary server and any changes to this file will be overwritten.
The default location of the DDC file is in the “conf” directory located under the “standby” sub directory.
If your Dbvisit Base directory is /usr/dbvisit, then you will find the DDC files in the /usr/dbvisit/standby/conf directory.
The DDC files have the following format: dbv_<DDC>.env, where DDC is in most cases the ORACLE_SID of your database, but this value can be different.
- dbv_testdb.env : testdb is a single instance database environment
- dbv_PROD1.env : PROD1 is the 1st instance in a 2 node RAC environment
- dbv_PROD2.env : PROD2 is the 2nd instance in a 2 node RAC environment
The DDC file can be created from either the CLI or the GUI, but it should be done from the primary server. If you are using Oracle RAC you have to follow the same steps on all the Nodes in the Oracle RAC configuration.
This section will cover the creation of the DDC file via the Command Line and via the GUI below.
Information Regarding Oracle RAC configurations
When installing Dbvisit Standby on Oracle RAC environments, please review this section, if you are using Single instance configurations please continue with the next section below.
For Oracle RAC installations please see - Configure Oracle RAC Primary with Oracle RAC Standby
When installing Dbvisit Standby on Oracle RAC on a UNIX based environment we recommend that you add an entry into each nodes /etc/oratab file for the corresponding instance.
Example if the Oracle RAC database is called DEV and you have instance DEV1 running on node 1 and instance DEV2 running on node 2 then you can add an entry for DEV1 into Node one /etc/oratab file and and entry for DEV2 into the /etc/oratab file of Node 2.
Example (the example below is showing for a RAC database called DEV using Oracle 11.2)
Standby Node, assuming it is single instance and you are calling the standby database DEV (same as primary), the standby /etc/oratab file might look like this:
Now when running the Dbvisit Setup you will get a question (if using command line) similar to the following, which will show you the Instance entry. Select 1 "DEV1" and continue with the setup. You should then end up with a DDC file named "dbv_DEV1.env".
Dbvisit can use the oratab file to find all the databases on this server.
If you would like Dbvisit to do this, please enter the location of the oratab file.
Specifying the oratab file is not mandatory.
Oratab file is [/etc/oratab]:
=>Oratab will be: /etc/oratab
Is this correct? <Yes/No> [Yes]:
The following Oracle instance(s) have been found on this server:
1) DEV1 /u01/app/oracle/product/11.2.0/db_1
2) DEV /u01/app/oracle/product/11.2.0/db_1
3) Enter own ORACLE_SID and ORACLE_HOME
Please enter choice : 1
The end result will be that you end up with two DDC files, on node 1 you will have a DDC file for instance 1 (dbv_DEV1.env) and for node 2 you will have a DDC file for instance 2 (dbv_DEV2.env). Both of them will have the standby database name as the same, in this case DEV (same as the primary).
Creating the DDC from the Command Line (Single and RAC Configurations)
To create a Dbvisit Database Configuration (DDC) file from the command line you need to run the “dbvisit_setup” command.
From the menu, select option 1 for Single Instance environments and if you are creating a DDC file for an Oracle RAC environment, you have to specify option 1a.
Once you have selected this option, follow the onscreen prompts and provide the information requested.
Note: If not using ASM for database storage, accept the default value of +ASM when asked for ASM details. Dbvisit Standby will automatically pick up ASM is not used and will ignore this value.
Below is an example of starting the DDC file creation:
Once you have specified option 1 follow the onscreen instructions, if using RAC, you must specify option 1a
The following questions will be asked (summary below)
The next step following the creation of the DDC file is to create a standby database, or if one already exists, run Dbvisit Standby as normal, first from the primary (which will then copy the DDC file to the standby location), followed by running it on the standby server.
Creating the DDC from the GUI
To create the Dbvisit Database Configuration file from the GUI interface you need to login to the web-based interface as the admin (default) user.
Once logged in select the “SETUP” button from the main screen.
You will then enter the Dbvisit Setup menu as seen below:
Once you have entered the "New Dbvisit Setup" section, you will be displayed with the screen blow. From this screen select the database you would like to configure Dbvisit Standby for (Create a DDC file for).
Dbvisit Standby will attempt to identify the databases running on the server. On Unix it will look for the Oracle "oratab" file, which should indicate all databases configured on the server and on Windows based systems, the information will be obtained from the Windows registry.
- You do not have to specify the Oracle SID. This is optional and will be obtained from the "oratab" file or "registry" if Windows is used. If your database is not listed in step 1 (drop down list), but is running, you can then manually add the Oracle SID.
- The Oracle Home will be obtained automatically and does not require andy value. But if the database was not listed in step 1 (drop down list), then you should specify the Oracle Home used for this database.
- This field will show the location of the /etc/oratab and in most cases does not require any changes.
Once you have selected the database in the step 1 above, a question will be asked confirming this is the primary server, confirm with Yes and then click continue.
Click on Yes to confirm this is the primary.
You will now be presented with the Main screen for a new Setup from where you will have to follow 7 steps (TABS) to complete the new configuration (creation of a DDC file)
STEP 1: Primary Server
This screen will take you through 7 tabs to create the Dbvisit Standby Database Configuration file.
Similar questions as mentioned for the CLI, will be asked as you move through these “tabs”.
Once you have completed all the information required in these 7 tabs, the DDC file as well as Dbvisit Database Repository (DDR) will be created.
- Specify the Dbvisit Standby Configuration (DDC) name. We recommend using the Database Name, and if using RAC use the INSTANCE Name from the server where you are running this configuration. Example, if you are running the configuration on Node 1 in a RAC configuration for RAC database PROD and on this node the database Instance name is PROD1, then we recommend you use PROD1 as the DDC name. In the above example the DDC name is called the same as the database "proddb" (single instance on this server).
- Specify the ASM Instance name on this server. If ASM is not used, ignore this field and leave the default value of +ASM. If you are using ASM, specify the ASM instance name running on this server. Example if this is a single instance environment (Non RAC), then the default ASM instance name will be +ASM. But if you are using RAC, the ASM instance name will be for example +ASM1 on node 1 and +ASM2 on node to.
- Specify the Dbvnet Port. The default port number 7890 is recommended. You need to make sure this port is open and not blocked by firewalls on the primary and standby servers.
- Dbvisit Standby is making use of a small database repository. The default schema (database username) is "dbvisit7"
- Specify the password for the repository owner (dbvisit7)
- Specify if the password should be encrypted in the DDC file or not. Default recommended value is Yes.
- Click on Next to continue.
STEP 2: Standby Server
- Specify the Standby Database Server Name
- Specify the DBVISIT_BASE location on the Standby Server (It is recommended that this location be the same on the Primary and Standby Server)
- Specify SSH Port (Not Required) The SSH Port is ignored on Windows Based systems. On Linux SSH can still be used, only if the DBVNET_PORT is not specified. The recommended option is to ignore this value (leave it at 22) and make use of Dbvnet.
- Specify the Oracle SID for the Standby Database. It is recommended to make use of the same name as what the primary database is called. Example if your primary database is called PROD, then you can call the Standby database PROD as well. In the above example the primary database is called "proddb" and the standby Oracle SID is specified the same - proddb.
- The Oracle Home value is optional. It is recommended that you add the standby database to the "oratab" file if configured on Unix.
- Specify the ASM Instance name on the Standby server. Ignore this value if you are not using ASM.
- IMPORTANT. This parameter must be set and this directory must exist on both the primary node(s) and the standby node. This location is used by Dbvisit Standby to store archive logs on the standby server from where they are applied to the Standby database. Note that this location is not the same as the Oracle Database archive destination (FRA/ Recovery Area). This location is also referred to as the Dbvisit Standby ARCHDEST.
STEP 3: RAC
- Specify if this is a RAC configuration (in the above example I am using a Single Instance - Non RAC configuration. If this was Oracle RAC, then specify "yes"
- Specify if this is the 1st RAC node in the configuration. This is required as Dbvisit Standby will create a repository and will only do this from the 1st RAC node.
- To enable RAC Takeover (recommended), specify Yes. This RAC node can take over the Dbvisit Processing of another node if that other node is down (unavailable)
- Specify if RAC Takeover should be forced, meaning this node will process the other RAC Node's archive logs (always), even if it is available.
- Specify the other RAC instance for which you want to take over processing (if that node is down, or if RAC Takeover Force is specified)
- Click on next to continue to the next Step (TAB).
STEP 4: MAIL
STEP 5: Primary AMM (Dbvisit Standby Archive Log Management Module)
STEP 6: Standby AMM (Dbvisit Standby Archive Log Management Module)
STEP 7: Finish
- You can now move on to either create the standby database if it does not exist, or you can run Dbvisit Standby as normal if a standby database is already in place.