spcopy

Purpose

Copies an Oracle ASM SPFILE from the source location to an SPFILE in the destination location.

Syntax and Description

spcopy [-u] source destination

Table 10-19 lists the options for the spcopy command.


Table 10-19 Options for the spcopy command

Option Description

-u

Updates the Grid Plug and Play (GPnP) profile.

source

Specifies the source file name.

destination

Specifies the destination.


Note the following about the use of spcopy:

  • spcopy can copy an Oracle ASM SPFILE from a disk group to a different disk group or to an operating system file.

  • spcopy can copy an Oracle ASM SPFILE from an operating system file to a disk group.

  • spcopy can copy an Oracle ASM SPFILE when the SPFILE is being used by an open Oracle ASM instance.

  • spcopy cannot make multiple copies of an Oracle ASM SPFILE in the same disk group. You can use spbackup for that purpose.

To update the GPnP profile, include the -u option with spcopy. You can also use spset to update the GPnP profile if spcopy is run without the -u option. See "spset". For information about copying and moving an Oracle ASM instance initialization parameter file after upgrading, see "About Backing Up_ Copying_ and Moving an Oracle ASM Initialization Parameter File".

After copying the SPFILE and updating the GPnP profile, you must restart the instance with the SPFILE in the new location to use that SPFILE. When the Oracle ASM instance is running with the SPFILE in the new location, you can remove the source SPFILE.

To copy an Oracle ASM SPFILE into a disk group using spcopy, the COMPATIBLE.ASM attribute must be set to 11.2 or greater in the target disk group.

See Also:

The CREATE SPFILE SQL statement in the Oracle Database SQL Language Reference for information about creating a server parameter file

Example

The following are examples of the spcopy command. The first example copies the Oracle ASM SPFILE from the data disk group to the fra disk group. The second example copies the Oracle ASM SPFILE from the data disk group to an operating system location. The third example copies an Oracle ASM SPFILE from an operating system location to the data disk group and updates the GPnP profile with the -u option.

Example 10-24 Using the ASMCMD spcopy command

ASMCMD> spcopy  +DATA/asm/asmparameterfile/registry.253.721810181
                +FRA/spfileCopyASM.ora

ASMCMD> spcopy +DATA/asm/asmparameterfile/registry.253.721810181
                $ORACLE_HOME/dbs/spfileCopyASM.ora

ASMCMD> spcopy -u /oracle/product/11.2.0/grid/dbs/spfileTestASM.ora
                  +DATA/ASM/spfileCopyASM.ora