15 DBMS_OFFLINE_OG

The DBMS_OFFLINE_OG package contains public APIs for offline instantiation of master groups.

This chapter contains this topic:

Note:

These procedures are used in performing an offline instantiation of a master table in a multimaster replication environment.

These procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.


Summary of DBMS_OFFLINE_OG Subprograms

Table 15-1 DBMS_OFFLINE_OG Package Subprograms

Subprogram Description

"BEGIN_INSTANTIATION Procedure"

Starts offline instantiation of a master group.

"BEGIN_LOAD Procedure"

Disables triggers while data is imported to new master site as part of offline instantiation.

"END_INSTANTIATION Procedure"

Completes offline instantiation of a master group.

"END_LOAD Procedure"

Reenables triggers after importing data to new master site as part of offline instantiation.

"RESUME_SUBSET_OF_MASTERS Procedure"

Resumes replication activity at all existing sites except the new site during offline instantiation of a master group.



BEGIN_INSTANTIATION Procedure

This procedure starts offline instantiation of a master group. You must call this procedure from the master definition site.

Note:

This procedure is used to perform an offline instantiation of a master table in a multimaster replication environment.

This procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.

See Also:

"Adding New Master Sites with Offline Instantiation Using Export/Import" for information about adding a new master site to a master group by performing an offline instantiation of a master site

Syntax


DBMS_OFFLINE_OG.BEGIN_INSTANTIATION (
   gname     IN   VARCHAR2,
   new_site  IN   VARCHAR2
   fname     IN   VARCHAR2);

Parameters

Table 15-2 BEGIN_INSTANTIATION Procedure Parameters

Parameter Description
gname

Name of the replication group that you want to replicate to the new site.

new_site

The fully qualified database name of the new site to which you want to replicate the replication group.

fname

This parameter is for internal use only.

Note: Do not set this parameter unless directed to do so by Oracle Support Services.


Exceptions

Table 15-3 BEGIN_INSTANTIATION Procedure Exceptions

Exception Description
badargument

NULL or empty string for replication group or new master site name.

dbms_repcat.nonmasterdef

This procedure must be called from the master definition site.

sitealreadyexists

Specified site is already a master site for this replication group.

wrongstate

Status of master definition site must be quiesced.

dbms_repcat.missingrepgroup

gname does not exist as a master group.

dbms_repcat.missing_flavor

If you receive this exception, contact Oracle Support Services.



BEGIN_LOAD Procedure

This procedure disables triggers while data is imported to the new master site as part of offline instantiation. You must call this procedure from the new master site.

Note:

This procedure is used to perform an offline instantiation of a master table in a multimaster replication environment.

This procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.

See Also:

"Adding New Master Sites with Offline Instantiation Using Export/Import" for information about adding a new master site to a master group by performing an offline instantiation of a master site

Syntax


DBMS_OFFLINE_OG.BEGIN_LOAD (
   gname     IN   VARCHAR2,
   new_site  IN   VARCHAR2);

Parameters

Table 15-4 BEGIN_LOAD Procedure Parameters

Parameter Description
gname

Name of the replication group whose members you are importing.

new_site

The fully qualified database name of the new site at which you will be importing the replication group members.


Exceptions

Table 15-5 BEGIN_LOAD Procedure Exceptions

Exception Description
badargument

NULL or empty string for replication group or new master site name.

wrongsite

This procedure must be called from the new master site.

unknownsite

Specified site is not recognized by replication group.

wrongstate

Status of the new master site must be quiesced.

dbms_repcat.missingrepgroup

gname does not exist as a master group.



END_INSTANTIATION Procedure

This procedure completes offline instantiation of a master group. You must call this procedure from the master definition site.

Note:

This procedure is used to perform an offline instantiation of a master table in a multimaster replication environment.

This procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.

See Also:

"Adding New Master Sites with Offline Instantiation Using Export/Import" for information about adding a new master site to a master group by performing an offline instantiation of a master site

Syntax


DBMS_OFFLINE_OG.END_INSTANTIATION (
  gname     IN  VARCHAR2,
  new_site  IN  VARCHAR2);

Parameters

Table 15-6 END_INSTANTIATION Procedure Parameters

Parameter Description
gname

Name of the replication group that you are replicating to the new site.

new_site

The fully qualified database name of the new site to which you are replicating the replication group.


Exceptions

Table 15-7 END_INSTANTIATION Procedure Exceptions

Exception Description
badargument

NULL or empty string for replication group or new master site name.

dbms_repcat.nonmasterdef

This procedure must be called from the master definition site.

unknownsite

Specified site is not recognized by replication group.

wrongstate

Status of master definition site must be quiesced.

dbms_repcat.missingrepgroup

gname does not exist as a master group.



END_LOAD Procedure

This procedure reenables triggers after importing data to new master site as part of offline instantiation. You must call this procedure from the new master site.

Note:

This procedure is used to perform an offline instantiation of a master table in a multimaster replication environment.

This procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.

See Also:

"Adding New Master Sites with Offline Instantiation Using Export/Import" for information about adding a new master site to a master group by performing an offline instantiation of a master site

Syntax


DBMS_OFFLINE_OG.END_LOAD (
   gname     IN   VARCHAR2,
   new_site  IN   VARCHAR2
   fname     IN   VARCHAR2);

Parameters

Table 15-8 END_LOAD Procedure Parameters

Parameter Description
gname

Name of the replication group whose members you have finished importing.

new_site

The fully qualified database name of the new site at which you have imported the replication group members.

fname

This parameter is for internal use only.

Note: Do not set this parameter unless directed to do so by Oracle Support Services.


Exceptions

Table 15-9 END_LOAD Procedure Exceptions

Exception Description
badargument

NULL or empty string for replication group or new master site name.

wrongsite

This procedure must be called from the new master site.

unknownsite

Specified site is not recognized by replication group.

wrongstate

Status of the new master site must be quiesced.

dbms_repcat.missingrepgroup

gname does not exist as a master group.

dbms_repcat.flavor_noobject

If you receive this exception, contact Oracle Support Services.

dbms_repcat.flavor_contains

If you receive this exception, contact Oracle Support Services.



RESUME_SUBSET_OF_MASTERS Procedure

When you add a new master site to a master group by performing an offline instantiation of a master site, it might take some time to complete the offline instantiation process. This procedure resumes replication activity at all existing sites, except the new site, during offline instantiation of a master group. You typically execute this procedure after executing the DBMS_OFFLINE_OG.BEGIN_INSTANTIATION procedure. You must call this procedure from the master definition site.

Note:

This procedure is used to perform an offline instantiation of a master table in a multimaster replication environment.

This procedure should not be confused with the procedures in the DBMS_REPCAT_INSTANTIATE package (used for instantiating a deployment template). See the documentation for this package for more information about its use.

See Also:

"Adding New Master Sites with Offline Instantiation Using Export/Import" for information about adding a new master site to a master group by performing an offline instantiation of a master site

Syntax


DBMS_OFFLINE_OG.RESUME_SUBSET_OF_MASTERS (
   gname     IN  VARCHAR2,
   new_site  IN  VARCHAR2
   override  IN  BOOLEAN := FALSE);

Parameters

Table 15-10 RESUME_SUBSET_OF_MASTERS Procedure Parameters

Parameter Description
gname

Name of the replication group that you are replicating to the new site.

new_site

The fully qualified database name of the new site to which you are replicating the replication group.

override

If this is TRUE, then any pending administrative requests are ignored and normal replication activity is restored at each master as quickly as possible. The override parameter should be set to TRUE only in emergency situations.

If this is FALSE, then normal replication activity is restored at each master only when there is no pending administrative request for gname at that master.


Exceptions

Table 15-11 RESUME_SUBSET_OF_MASTERS Procedure Exceptions

Exception Description
badargument

NULL or empty string for replication group or new master site name.

dbms_repcat.nonmasterdef

This procedure must be called from the master definition site.

unknownsite

Specified site is not recognized by replication group.

wrongstate

Status of master definition site must be quiesced.

dbms_repcat.missingrepgroup

gname does not exist as a master group.