FAQ
Hi
I am thinking about different scenarios that need to be tested in our new
linux infrastructure which will have 11gR2 GI and this will be supporting
our 11gR1 databases.
One of the scenarios is some times to refresh a development instance from
another development instance and I had this question

(a) db1 and db2 are two databases on the same box node1.
(b) db1 uses a diskgroup called db1_dg and db2 uses a diskgroup called
db2_dg
(c) Perform a bcv copy from db1_dg to db2_dg (of course db2_dg and the
associated database will be down during this time)
(d)At this point, he headers of the files/devices that make up db2_dg will
have information about db1_dg
(e) I cant bring up db2_dg unless I use the rename command and rename the
headers of db2_dg (from the ones pointing to db1_dg) to db2_dg.
Questions are:

How can I accomplish this using rename command
renamedg phase=both dgname=db1_dg newdgname=db2_dg
If I use this, I am afraid that I will wipe out the source.

Thank you
Kumar

Search Discussions

  • Yong Huang at Feb 8, 2011 at 3:46 pm

    (c) Perform a bcv copy from db1_dg to db2_dg
    (d)At this point, the headers of the files/devices that make up
    db2_dg will have information about db1_dg ...
    How can I accomplish this using rename command
    renamedg phase=both dgname=db1_dg newdgname=db2_dg
    If I use this, I am afraid that I will wipe out the source.
    Interesting question. I've never done it. But I suppose if you pass the
    asm_diskstring option to renamedg, you can specifically point to the disks
    comprising the *target* diskgroup only. It may be a good idea to open an SR
    with Oracle.

    Yong Huang
  • Mathias Zarick at Feb 8, 2011 at 7:57 pm
    Hi Kumar,

    use renamedg's parameter asm_diskstring to restrict to the devices in question.
    renamedg dgname=db1_dg newdgname=db2_dg asm_diskstring=/dev/sdb verbose=true
    HTH Mathias

    From: oracle-l-bounce_at_freelists.org On Behalf Of Kumar Madduri
    Sent: Monday, February 07, 2011 6:48 PM
    To: oracle Freelists
    Subject: Clarification on rename dg command

    Hi
    I am thinking about different scenarios that need to be tested in our new linux infrastructure which will have 11gR2 GI and this will be supporting our 11gR1 databases.
    One of the scenarios is some times to refresh a development instance from another development instance and I had this question

    (a) db1 and db2 are two databases on the same box node1.
    (b) db1 uses a diskgroup called db1_dg and db2 uses a diskgroup called db2_dg
    (c) Perform a bcv copy from db1_dg to db2_dg (of course db2_dg and the associated database will be down during this time)
    (d)At this point, he headers of the files/devices that make up db2_dg will have information about db1_dg
    (e) I cant bring up db2_dg unless I use the rename command and rename the headers of db2_dg (from the ones pointing to db1_dg) to db2_dg.
    Questions are:

    How can I accomplish this using rename command
    renamedg phase=both dgname=db1_dg newdgname=db2_dg
    If I use this, I am afraid that I will wipe out the source.

    Thank you
    Kumar
  • Martin Berger at Feb 8, 2011 at 8:36 pm
    Kumar,

    Mathias' suggestions are quite good.
    If you want to make 100% sure, you do not touch the wrong disks, you can do something more complex, but quite funny.

    start a 2nd ASM instance on the same server (!)
    for this you only need to set a different ORACLE_SID and make sure in the new spfile you have another DB_UNIQUE_NAME.
    Make any dedicated directory you like, and set the ASM_DISKSTRING of that specific ASM instance to this directory.
    Now create a symlink of every disk you want to manipulate into this particular directory.
    To be soure, check v$asm_disks in this ASM to make sure you see only the disks you want to manipulate.
    Now you can run renamedg as Mathias described, just skip the asm_diskstrin parameter.

    Even it's uncommon to have 2 ASM instances on one host, i's really stable for such tasks and prevents some issues you cah face if you try the stunt with only one ASM.

    hth,
    Martin

    Am 07.02.2011 um 18:48 schrieb Kumar Madduri:
    Hi
    I am thinking about different scenarios that need to be tested in our new linux infrastructure which will have 11gR2 GI and this will be supporting our 11gR1 databases.
    One of the scenarios is some times to refresh a development instance from another development instance and I had this question

    (a) db1 and db2 are two databases on the same box node1.
    (b) db1 uses a diskgroup called db1_dg and db2 uses a diskgroup called db2_dg
    (c) Perform a bcv copy from db1_dg to db2_dg (of course db2_dg and the associated database will be down during this time)
    (d)At this point, he headers of the files/devices that make up db2_dg will have information about db1_dg
    (e) I cant bring up db2_dg unless I use the rename command and rename the headers of db2_dg (from the ones pointing to db1_dg) to db2_dg.
    Questions are:

    How can I accomplish this using rename command
    renamedg phase=both dgname=db1_dg newdgname=db2_dg
    If I use this, I am afraid that I will wipe out the source.


    Thank you
    Kumar
    --
    http://www.freelists.org/webpage/oracle-l
  • Kumar Madduri at Feb 11, 2011 at 5:01 am
    Update on this: Like Yong and Mathias suggested, the asm diskstring
    parameter in renamedg worked. Thank you for the suggestions.
    Martin: Actually I did try to bring up 2 asm instances on the same box
    earlier (in 11.1.0.7 cluster) and it allowed me to do so. With 11gR2 I was
    not able to bring it up and let clusterware also realize the other ASM
    instance. May be it was the combination in R2 (grid +asm) that did not allow
    me to bring it up this way.

    kumar
    On Tue, Feb 8, 2011 at 12:36 PM, Martin Berger wrote:

    Kumar,

    Mathias' suggestions are quite good.
    If you want to make 100% sure, you do not touch the wrong disks, you can do
    something more complex, but quite funny.

    start a 2nd ASM instance on the same server (!)
    for this you only need to set a different ORACLE_SID and make sure in the
    new spfile you have another DB_UNIQUE_NAME<http://download.oracle.com/docs/cd/B28359_01/server.111/b28320/initparams065.htm#REFRN10242>
    .
    Make any dedicated directory you like, and set the ASM_DISKSTRING<http://download.oracle.com/docs/cd/B28359_01/server.111/b28320/initparams011.htm#REFRN10248> of
    that specific ASM instance to this directory.
    Now create a symlink of every disk you want to manipulate into this
    particular directory.
    To be soure, check v$asm_disks in this ASM to make sure you see only the
    disks you want to manipulate.
    Now you can run renamedg as Mathias described, just skip the asm_diskstrin
    parameter.

    Even it's uncommon to have 2 ASM instances on one host, i's really stable
    for such tasks and prevents some issues you cah face if you try the stunt
    with only one ASM.

    hth,
    Martin

    Am 07.02.2011 um 18:48 schrieb Kumar Madduri:

    Hi
    I am thinking about different scenarios that need to be tested in our new
    linux infrastructure which will have 11gR2 GI and this will be supporting
    our 11gR1 databases.
    One of the scenarios is some times to refresh a development instance from
    another development instance and I had this question

    (a) db1 and db2 are two databases on the same box node1.
    (b) db1 uses a diskgroup called db1_dg and db2 uses a diskgroup called
    db2_dg
    (c) Perform a bcv copy from db1_dg to db2_dg (of course db2_dg and the
    associated database will be down during this time)
    (d)At this point, he headers of the files/devices that make up db2_dg will
    have information about db1_dg
    (e) I cant bring up db2_dg unless I use the rename command and rename the
    headers of db2_dg (from the ones pointing to db1_dg) to db2_dg.
    Questions are:

    How can I accomplish this using rename command
    renamedg phase=both dgname=db1_dg newdgname=db2_dg
    If I use this, I am afraid that I will wipe out the source.


    Thank you
    Kumar

    --
    http://www.freelists.org/webpage/oracle-l

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouporacle-l @
categoriesoracle
postedFeb 7, '11 at 5:48p
activeFeb 11, '11 at 5:01a
posts5
users4
websiteoracle.com

People

Translate

site design / logo © 2022 Grokbase