Tag: Exadata Compute Node

  • Step-by-step Guide of Exadata Snapshot Based Backup of Compute Node to NFS Share

    Step-by-step Guide of Exadata Snapshot Based Backup of Compute Node to NFS Share

     

    Backing up file systems on Oracle Exadata compute can be a daunting task if you are unaware of the prerequisites and best practices. To help you backup your file systems effectively and with least discrepancies, we are bringing you this interesting step-by-step guide on how to back up your file system using Oracle Exadata Sanpshot Based Backup of Compute Node to NFS Share    

     

    It is very important to take file system backup on Oracle Exadata compute nodes before we make any major changes to the operating system or critical software. On Oracle Exadata Compute nodes / (root) and /u01 file systems contains the operating system and GI/DB software respectively. These are the most critical file systems on Oracle Exadata computes.

     

    By default, the / (root) and /u01 file system are sized 30GB and 100GB respectively.

     

    Scenarios in which we must take file system backup are:

     

    • – Operating System Patching or Upgrade
    •  
    • – Grid Infrastructure Patching or Upgrade
    •  
    • – Database Patching or Upgrade
    •  
    • – Operating System configuration changes
    •  
    • – Increasing/decreasing file system size

     

    In this article, we will demonstrate how to backup file system on Oracle Exadata Compute nodes running Linux Operating System to external storage NFS Share.

    eBook - Oracle Exadata X8M Patching Recipes | Netsoftmate

    Environment Details

     

    Exadata Model

    X4-2 Half Rack HP 4 TB

    Exadata Components

    4 – Compute nodes, 7 – Storage cells & 2 – IB switches

    Exadata Storage cells

    DBM01CEL01 – DBM01CEL07

    Exadata Compute nodes

    DBM01DB01 – DBM01DB04

    Exadata Software Version

    19.2.3.0

    Exadata DB Version

    11.2.0.4.180717

     

     

    Prerequisites

     

    • – Root user access on Compute nodes
    •  
    • – NFS mount with sufficient storage to storing file system backup

    Current root and /u01 file system sizes

     

    [root@ip01db01 ~]# df -h / /u01

    Filesystem Size  Used Avail Use% Mounted on

    /dev/mapper/VGExaDb-LVDbSys1   59G   39G   18G  70% /

    /dev/mapper/VGExaDb-LVDbOra1  197G  171G   17G  92% /u01

    NFS share details

     

    10.10.10.1:/nfs/backup/

     

    • 1. As root user, log in to the Exadata Compute node you wish to backup

     

    [root@ip01db01 ~]# id root

    uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel)

     

    • 2. Create a mount point to mount NFS share

     

    [root@dm01db01 ~]# mkdir -p /mnt/backup

    [root@dm01db01 ~]# mount -t nfs -o rw,intr,soft,proto=tcp,nolock 10.10.10.1:/nfs/backup/ /mnt/backup

     

    3. Determine the file system type extension root and u01 file system

     

    [root@ip01db01 ~]# mount -l

    sysfs on /sys type sysfs (rw,relatime)

    proc on /proc type proc (rw,relatime)

    devtmpfs on /dev type devtmpfs (rw,nosuid,size=131804372k,nr_inodes=32951093,mode=755)

    securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)

    tmpfs on /dev/shm type tmpfs (rw,size=264225792k)

    /dev/mapper/VGExaDb-LVDbSys1 on / type ext3 (rw,relatime,errors=continue,barrier=1,data=ordered) [DBSYS]

    /dev/mapper/VGExaDb-LVDbOra1 on /u01 type ext3 (rw,nodev,relatime,errors=continue,barrier=1,data=ordered) [DBORA]

    /dev/sda1 on /boot type ext3 (rw,nodev,relatime,errors=continue,barrier=1,data=ordered) [BOOT]

     

     

    4.  Note down the file system type for root and /u01: ext3. Take a snapshot-based of the root and u01 directories, Label the snapshot and Mount the snapshot

     

    [root@dm01db01 ~]# lvcreate -L5G -s -n root_snap /dev/VGExaDb/LVDbSys1

      Logical volume “root_snap” created.

     

    [root@dm01db01 ~]# lvcreate -L5G -s -n u01_snap /dev/VGExaDb/LVDbOra1

      Logical volume “u01_snap” created.

    [root@dm01db01 ~]# e2label /dev/VGExaDb/root_snap DBSYS_SNAP

    [root@dm01db01 ~]# e2label /dev/VGExaDb/u01_snap DBORA_SNAP

     

    [root@dm01db01 ~]# mkdir -p /mnt/snap/root

    [root@dm01db01 ~]# mkdir -p /mnt/snap/u01

     

     

    [root@dm01db01 ~]# mount /dev/VGExaDb/root_snap /mnt/snap/root -t ext3

    [root@dm01db01 ~]# mount /dev/VGExaDb/u01_snap /mnt/snap/u01 -t ext3

     

     

    [root@dm01db01 ~]# df -h /mnt/snap/root

    [root@dm01db01 ~]# df -h /mnt/snap/u01

     

     

    • 5. Change to the directory for the backup and Create the backup file

     

    [root@dm01db01 ~]#  cd /mnt/backup

     

    [root@dm01db01 ~]#  tar -pjcvf /mnt/backup/mybackup.tar.bz2 * /boot –exclude /mnt/backup/mybackup.tar.bz2 > /tmp/backup_tar.stdout 2> /tmp/backup_tar.stderr

     

    • 6. Monitor the /tmp/backup_tar.stderr file for errors. Errors such as failing to tar open sockets can be ignored.

     

    • 7. Unmount the snapshots and remove the snapshots for the root and /01 directories.

     

    [root@dm01db01 ~]# cd /

     

    [root@dm01db01 /]# umount /mnt/snap/u01

     

    [root@dm01db01 /]# umount /mnt/snap/root

     

    [root@dm01db01 /]# df -h /mnt/snap/u01

    [root@dm01db01 /]# df -h /mnt/snap/root

     

    [root@dm01db01 /]# ls -l /mnt/snap

     

    [root@dm01db01 /]# rm -rf /mnt/snap

     

     

    [root@dm01db01 /]# lvremove /dev/VGExaDb/u01_snap

    Do you really want to remove active logical volume u01_snap? [y/n]: y

      Logical volume “u01_snap” successfully removed

     

    [root@dm01db01 /]# lvremove /dev/VGExaDb/root_snap

    Do you really want to remove active logical volume root_snap? [y/n]: y

      Logical volume “root_snap” successfully removed

     

    • 8. Unmount the NFS share

     

    [root@dm01db01 /] umount /mnt/backup

     

    • Repeat the above steps on the remaining compute nodes to backup root & u01 file system

    We hope this article helps you smoothly backup your file system on Oracle Exadata Compute node running Oracle Linux using NFS Share. Stay tuned for more step-by-step guides on implementing and using Oracle Database Systems exclusively on Netsoftmate

    Netsoftmate provides the best standard services when it comes to Oracle databases management, covering all comples database products. Sign-up for a free 30 minutes call by clicking on the link below –

    Click here and fill the contact us form for a free 30 minutes consultation

     

  • Move Database from DATA to RECO ASM Disk Group On Exadata

    Exadata Database machine consists of 3 ASM Disk Groups:
    +DATA for Database Files
    +RECO for Online Redo log and Archive log files
    +DBFS_DG for Cluster configuration files such as OCR and Voting disks


    In a Customized environment Customers can choose to have more than 3 Disk Groups. But it is recommended to have 3 Disk Groups. The DATA and RECO disk groups can be sized 80%-20% or 40%-60% respectively of over all storage capacity. Sometimes it is possible that +DATA disk group can be filled very fast if you have several databases.


    In this article we will demostrate how to move a Database from +DATA disk group to +RECO disk group.




    Steps to move a database from +DATA to +RECO ASM Disk Group:




    Step 1: Get the ASM Disk Information


    SQL> select state,name from v$asm_diskgroup;


    STATE       NAME
    ———– ——————————
    MOUNTED     RECO
    MOUNTED     DBFS_DG
    MOUNTED     DATA




    Step 2: Get the Database files details


    SQL> select name, open_mode,database_role from gv$database;


    NAME      OPEN_MODE            DATABASE_ROLE
    ——— ——————– —————-
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY


    SQL> select name from v$controlfile;


    NAME
    ——————————————————————————–
    +DATA/dbm01/controlfile/current.256.976374731


    SQL> select name from v$datafile;


    NAME
    ——————————————————————————–
    +DATA/dbm01/datafile/system.259.976374739
    +DATA/dbm01/datafile/sysaux.260.976374743
    +DATA/dbm01/datafile/undotbs1.261.976374745
    +DATA/dbm01/datafile/undotbs2.263.976374753
    +DATA/dbm01/datafile/undotbs3.264.976374755
    +DATA/dbm01/datafile/undotbs4.265.976374757
    +DATA/dbm01/datafile/users.266.976374757


    7 rows selected.


    SQL> select name from v$tempfile;


    NAME
    ——————————————————————————–
    +DATAC1/dbm01/tempfile/temp.262.976375229


    SQL>


    SQL> select member from v$logfile;


    MEMBER
    ——————————————————————————–
    +DATA/dbm01/onlinelog/group_1.257.976374733
    +DATA/dbm01/onlinelog/group_2.258.976374735
    +DATA/dbm01/onlinelog/group_7.267.976375073
    +DATA/dbm01/onlinelog/group_8.268.976375075
    +DATA/dbm01/onlinelog/group_5.269.976375079
    +DATA/dbm01/onlinelog/group_6.270.976375083
    +DATA/dbm01/onlinelog/group_3.271.976375085
    +DATA/dbm01/onlinelog/group_4.272.976375087
    +DATA/dbm01/onlinelog/group_9.274.976375205
    +DATA/dbm01/onlinelog/group_10.275.976375209
    +DATA/dbm01/onlinelog/group_11.276.976375211
    +DATA/dbm01/onlinelog/group_12.277.976375215
    +DATA/dbm01/onlinelog/group_13.278.976375217
    +DATA/dbm01/onlinelog/group_14.279.976375219
    +DATA/dbm01/onlinelog/group_15.280.976375223
    +DATA/dbm01/onlinelog/group_16.281.976375225


    16 rows selected.


    SQL> select filename from v$block_change_tracking;


    FILENAME
    ——————————————————————–
    +DATA/dbm01/changetracking/ctf.282.976375227




    Step 3: Backup Database using RMAN copy command as shown below. Here we are moving database to +RECO ASM Disk Group.


    RMAN> run {
    allocate channel c1 device type disk;
    allocate channel c2 device type disk;
    allocate channel c3 device type disk;
    allocate channel c4 device type disk;
    allocate channel c5 device type disk;
    allocate channel c6 device type disk;
    allocate channel c7 device type disk;
    allocate channel c8 device type disk;
    backup as copy database include current controlfile format ‘+RECO’;
    release channel c1;
    release channel c2;
    release channel c3;
    release channel c4;
    release channel c5;
    release channel c6;
    release channel c7;
    release channel c8;
    }


    released channel: ORA_DISK_1
    allocated channel: c1
    channel c1: SID=1189 instance=dbm011 device type=DISK


    allocated channel: c2
    channel c2: SID=1321 instance=dbm011 device type=DISK


    allocated channel: c3
    channel c3: SID=1343 instance=dbm011 device type=DISK


    allocated channel: c4
    channel c4: SID=1387 instance=dbm011 device type=DISK


    allocated channel: c5
    channel c5: SID=1497 instance=dbm011 device type=DISK


    allocated channel: c6
    channel c6: SID=1519 instance=dbm011 device type=DISK


    allocated channel: c7
    channel c7: SID=1541 instance=dbm011 device type=DISK


    allocated channel: c8
    channel c8: SID=1563 instance=dbm011 device type=DISK


    Starting backup at 26-MAY-18
    channel c1: starting datafile copy
    input datafile file number=00001 name=+DATA/dbm01/datafile/system.259.976374739
    channel c2: starting datafile copy
    input datafile file number=00002 name=+DATA/dbm01/datafile/sysaux.260.976374743
    channel c3: starting datafile copy
    input datafile file number=00003 name=+DATA/dbm01/datafile/undotbs1.261.976374745
    channel c4: starting datafile copy
    input datafile file number=00004 name=+DATA/dbm01/datafile/undotbs2.263.976374753
    channel c5: starting datafile copy
    input datafile file number=00005 name=+DATA/dbm01/datafile/undotbs3.264.976374755
    channel c6: starting datafile copy
    input datafile file number=00006 name=+DATA/dbm01/datafile/undotbs4.265.976374757
    channel c7: starting datafile copy
    input datafile file number=00007 name=+DATA/dbm01/datafile/users.266.976374757
    channel c8: starting datafile copy
    copying current control file
    output file name=+RECO/dbm01/datafile/users.284.977121353 tag=TAG20180526T063551 RECID=16 STAMP=977121353
    channel c7: datafile copy complete, elapsed time: 00:00:02
    output file name=+RECO/dbm01/controlfile/backup.283.977121353 tag=TAG20180526T063551 RECID=17 STAMP=977121353
    channel c8: datafile copy complete, elapsed time: 00:00:01
    output file name=+RECO/dbm01/datafile/system.291.977121353 tag=TAG20180526T063551 RECID=18 STAMP=977121389
    channel c1: datafile copy complete, elapsed time: 00:00:46
    output file name=+RECO/dbm01/datafile/sysaux.290.977121353 tag=TAG20180526T063551 RECID=23 STAMP=977121392
    channel c2: datafile copy complete, elapsed time: 00:00:46
    output file name=+RECO/dbm01/datafile/undotbs1.289.977121353 tag=TAG20180526T063551 RECID=21 STAMP=977121392
    channel c3: datafile copy complete, elapsed time: 00:00:46
    output file name=+RECO/dbm01/datafile/undotbs2.288.977121353 tag=TAG20180526T063551 RECID=19 STAMP=977121392
    channel c4: datafile copy complete, elapsed time: 00:00:46
    output file name=+RECO/dbm01/datafile/undotbs3.287.977121353 tag=TAG20180526T063551 RECID=20 STAMP=977121392
    channel c5: datafile copy complete, elapsed time: 00:00:46
    output file name=+RECO/dbm01/datafile/undotbs4.286.977121353 tag=TAG20180526T063551 RECID=22 STAMP=977121392
    channel c6: datafile copy complete, elapsed time: 00:00:46
    Finished backup at 26-MAY-18


    Starting Control File and SPFILE Autobackup at 26-MAY-18
    piece handle=+RECO/dbm01/autobackup/2018_05_26/s_977121397.282.977121399 comment=NONE
    Finished Control File and SPFILE Autobackup at 26-MAY-18


    released channel: c1


    released channel: c2


    released channel: c3


    released channel: c4


    released channel: c5


    released channel: c6


    released channel: c7


    released channel: c8




    Step 4: Verify the RMAN Database Copy using RMAN


    RMAN> list copy of database;


    List of Datafile Copies
    =======================


    Key     File S Completion Time Ckp SCN    Ckp Time
    ——- —- – ————— ———- —————
    18      1    A 26-MAY-18       1330853    26-MAY-18
            Name: +RECO/dbm01/datafile/system.291.977121353
            Tag: TAG20180526T063551


    9       1    A 26-MAY-18       1330410    26-MAY-18
            Name: +RECO/dbm01/datafile/system.286.977120961
            Tag: TAG20180526T062919


    3       1    A 26-MAY-18       1330155    26-MAY-18
            Name: +RECO/dbm01/datafile/system.280.977120795
            Tag: TAG20180526T062633


    23      2    A 26-MAY-18       1330856    26-MAY-18
            Name: +RECO/dbm01/datafile/sysaux.290.977121353
            Tag: TAG20180526T063551


    12      2    A 26-MAY-18       1330413    26-MAY-18
            Name: +RECO/dbm01/datafile/sysaux.287.977120961
            Tag: TAG20180526T062919


    2       2    A 26-MAY-18       1330158    26-MAY-18
            Name: +RECO/dbm01/datafile/sysaux.281.977120795
            Tag: TAG20180526T062633


    21      3    A 26-MAY-18       1330859    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs1.289.977121353
            Tag: TAG20180526T063551


    11      3    A 26-MAY-18       1330416    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs1.288.977120961
            Tag: TAG20180526T062919


    4       3    A 26-MAY-18       1330154    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs1.279.977120795
            Tag: TAG20180526T062633


    19      4    A 26-MAY-18       1330862    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs2.288.977121353
            Tag: TAG20180526T063551


    10      4    A 26-MAY-18       1330419    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs2.289.977120961
            Tag: TAG20180526T062919


    1       4    A 26-MAY-18       1330153    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs2.278.977120795
            Tag: TAG20180526T062633


    20      5    A 26-MAY-18       1330865    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs3.287.977121353
            Tag: TAG20180526T063551


    13      5    A 26-MAY-18       1330422    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs3.290.977120961
            Tag: TAG20180526T062919


    7       5    A 26-MAY-18       1330184    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs3.282.977120829
            Tag: TAG20180526T062633


    22      6    A 26-MAY-18       1330868    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs4.286.977121353
            Tag: TAG20180526T063551


    15      6    A 26-MAY-18       1330425    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs4.291.977120961
            Tag: TAG20180526T062919


    6       6    A 26-MAY-18       1330187    26-MAY-18
            Name: +RECO/dbm01/datafile/undotbs4.283.977120829
            Tag: TAG20180526T062633


    16      7    A 26-MAY-18       1330871    26-MAY-18
            Name: +RECO/dbm01/datafile/users.284.977121353
            Tag: TAG20180526T063551


    8       7    A 26-MAY-18       1330428    26-MAY-18
            Name: +RECO/dbm01/datafile/users.292.977120961
            Tag: TAG20180526T062919


    5       7    A 26-MAY-18       1330190    26-MAY-18
            Name: +RECO/dbm01/datafile/users.284.977120829
            Tag: TAG20180526T062633


    RMAN> list copy of controlfile;


    List of Control File Copies
    ===========================


    Key     S Completion Time Ckp SCN    Ckp Time
    ——- – ————— ———- —————
    17      A 26-MAY-18       1330876    26-MAY-18
            Name: +RECO/dbm01/controlfile/backup.283.977121353
            Tag: TAG20180526T063551


    14      A 26-MAY-18       1330434    26-MAY-18
            Name: +RECO/dbm01/controlfile/backup.293.977120965
            Tag: TAG20180526T062919




    Step 5: Verify the RMAN Database Copy backup in ASM


    [oracle@dm01db01 ~]$ asmcmd -p
    ASMCMD [+] > lsdg
    State    Type    Rebal  Sector  Block       AU   Total_MB    Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH    N         512   4096  4194304  272154624  271558968          6479872        88359698              0             N  DATA/
    MOUNTED  HIGH    N         512   4096  4194304    2404640    2402468            68704          777921              0             Y  DBFS_DG/
    MOUNTED  NORMAL  N         512   4096  4194304   45389568   45183784           540352        22321716              0             N  RECO/


    ASMCMD [+] > cd +RECO


    ASMCMD [+RECO] > ls -l
    Type  Redund  Striped  Time             Sys  Name
                                            Y    DBM01/
    ASMCMD [+RECO] > cd DBM01
    ASMCMD [+RECO/DBM01] > ls -l
    Type         Redund  Striped  Time             Sys  Name
                                                   Y    ARCHIVELOG/
                                                   Y    AUTOBACKUP/
                                                   Y    CONTROLFILE/
                                                   Y    DATAFILE/
                                                   N    snapcf_dbm01.f => +RECO/DBM01/CONTROLFILE/Backup.285.977120961
    ASMCMD [+RECO/DBM01] > ls -l DATAFILE/
    Type      Redund  Striped  Time             Sys  Name
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    SYSAUX.290.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    SYSTEM.291.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    UNDOTBS1.289.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    UNDOTBS2.288.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    UNDOTBS3.287.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    UNDOTBS4.286.977121353
    DATAFILE  MIRROR  COARSE   MAY 26 06:00:00  Y    USERS.284.977121353
    ASMCMD [+RECO/DBM01] > ls -l CONTROLFILE/
    Type         Redund  Striped  Time             Sys  Name
    CONTROLFILE  HIGH    FINE     MAY 26 06:00:00  Y    Backup.283.977121353
    CONTROLFILE  HIGH    FINE     MAY 26 06:00:00  Y    Backup.285.977120961
    CONTROLFILE  HIGH    FINE     MAY 26 06:00:00  Y    Backup.293.977120965


    Step 6: Switch Database to RMAN backup copy. This command will switch the database from +DATA to +RECO ASM Disk Group.


    [oracle@dm01db01 ~]$ srvctl stop database -d dbm01


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Sat May 26 07:22:06 2018


    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to an idle instance.


    SQL> startup mount;
    ORACLE instance started.


    Total System Global Area 2.5655E+10 bytes
    Fixed Size                  2265224 bytes
    Variable Size            4160753528 bytes
    Database Buffers         2.1341E+10 bytes
    Redo Buffers              151113728 bytes
    Database mounted.


    [oracle@dm01db01 ~]$ rman target /


    Recovery Manager: Release 11.2.0.4.0 – Production on Sat May 26 07:23:09 2018


    Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.


    connected to target database: DBM01 (DBID=1180720008, not open)


    RMAN> switch database to copy;


    using target database control file instead of recovery catalog
    datafile 1 switched to datafile copy “+RECO/dbm01/datafile/system.291.977121353”
    datafile 2 switched to datafile copy “+RECO/dbm01/datafile/sysaux.290.977121353”
    datafile 3 switched to datafile copy “+RECO/dbm01/datafile/undotbs1.289.977121353”
    datafile 4 switched to datafile copy “+RECO/dbm01/datafile/undotbs2.288.977121353”
    datafile 5 switched to datafile copy “+RECO/dbm01/datafile/undotbs3.287.977121353”
    datafile 6 switched to datafile copy “+RECO/dbm01/datafile/undotbs4.286.977121353”
    datafile 7 switched to datafile copy “+RECO/dbm01/datafile/users.284.977121353”


    RMAN> recover database;


    Starting recover at 26-MAY-18
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=991 instance=dbm011 device type=DISK


    starting media recovery
    media recovery complete, elapsed time: 00:00:02


    Finished recover at 26-MAY-18


    RMAN> alter database open resetlogs;


    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of alter db command at 05/26/2018 07:25:06
    ORA-01139: RESETLOGS option only valid after an incomplete database recovery


    RMAN> alter database open;


    database opened


    [oracle@dm01db01 ~]$ srvctl stop database -d dbm01


    [oracle@dm01db01 ~]$ srvctl start database -d dbm01


    [oracle@dm01db01 ~]$ srvctl status database -d dbm01
    Instance dbm011 is running on node dm01db01
    Instance dbm012 is running on node dm01db02
    Instance dbm013 is running on node dm01db03
    Instance dbm014 is running on node dm01db04


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Sat May 26 07:28:11 2018


    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> select name, open_mode,database_role from gv$database;


    NAME      OPEN_MODE            DATABASE_ROLE
    ——— ——————– —————-
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY




    Step 7: Move Temp and online redo log files


    SQL> alter database tempfile ‘+DATAC1/dbm01/tempfile/temp.262.976375229’ drop;


    Database altered.


    SQL> alter tablespace TEMP add tempfile ‘+RECO’ SIZE 1024M;


    Tablespace altered.


    SQL> alter database add logfile member ‘+RECO’ to group 1;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 2;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 3;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 4;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 5;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 6;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 7;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 8;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 9;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 10;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 11;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 12;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 13;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 14;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 15;


    Database altered.


    SQL> alter database add logfile member ‘+RECO’ to group 16;


    Database altered.


    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_1.257.976374733’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_2.258.976374735’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_7.267.976375073’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_8.268.976375075’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_5.269.976375079’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_6.270.976375083’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_3.271.976375085’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_4.272.976375087’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_9.274.976375205’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_10.275.976375209’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_11.276.976375211’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_12.277.976375215’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_13.278.976375217’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_14.279.976375219’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_15.280.976375223’;
    SQL> alter database drop logfile member ‘+DATA/dbm01/onlinelog/group_16.281.976375225’;




    Step 8: Move control file to +RECO Disk Group


    [oracle@dm01db01 ~]$ srvctl stop database -d dbm01
    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Sat May 26 08:53:35 2018


    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to an idle instance.


    SQL> startup nomount;
    ORACLE instance started.


    Total System Global Area 2.5655E+10 bytes
    Fixed Size                  2265224 bytes
    Variable Size            4429188984 bytes
    Database Buffers         2.1072E+10 bytes
    Redo Buffers              151113728 bytes
    SQL> exit
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, OLAP, Data Mining
    and Real Application Testing options
    [oracle@dm01db01 ~]$ rman target /


    Recovery Manager: Release 11.2.0.4.0 – Production on Sat May 26 08:53:59 2018


    Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.


    connected to target database: DBM01 (not mounted)


    RMAN> restore controlfile to ‘+RECO’ from ‘+DATA/dbm01/controlfile/current.256.976374731’;


    Starting restore at 26-MAY-18
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=969 instance=dbm011 device type=DISK


    channel ORA_DISK_1: copied control file copy
    Finished restore at 26-MAY-18


    RMAN> exit


    Recovery Manager complete.


    [oracle@dm01db01 ~]$ . oraenv
    ORACLE_SID = [dbm011] ? +ASM1
    The Oracle base remains unchanged with value /u01/app/oracle


    [oracle@dm01db01 ~]$ asmcmd -p


    ASMCMD [+] > cd +RECO


    ASMCMD [+RECO] > ls -l
    Type  Redund  Striped  Time             Sys  Name
                                            Y    DBM01/
    ASMCMD [+RECO] > cd DBM01
    ASMCMD [+RECO/DBM01] > ls -l
    Type         Redund  Striped  Time             Sys  Name
                                                   Y    ARCHIVELOG/
                                                   Y    AUTOBACKUP/
                                                   Y    CHANGETRACKING/
                                                   Y    CONTROLFILE/
                                                   Y    DATAFILE/
                                                   Y    ONLINELOG/
                                                   Y    TEMPFILE/
                                                   N    snapcf_dbm01.f => +RECO/DBM01/CONTROLFILE/Backup.285.977120961
    ASMCMD [+RECO/DBM01] > cd CONTROLFILE/


    ASMCMD [+RECO/DBM01/CONTROLFILE] > ls -l
    Type         Redund  Striped  Time             Sys  Name
    CONTROLFILE  HIGH    FINE     MAY 26 06:00:00  Y    Backup.283.977121353
    CONTROLFILE  HIGH    FINE     MAY 26 08:00:00  Y    Backup.285.977120961
    CONTROLFILE  HIGH    FINE     MAY 26 06:00:00  Y    Backup.293.977120965
    CONTROLFILE  HIGH    FINE     MAY 26 08:00:00  Y    Backup.321.977128799
    CONTROLFILE  HIGH    FINE     MAY 26 08:00:00  Y    current.331.977129649


    ASMCMD [+RECO/DBM01/CONTROLFILE] > pwd
    +RECO/DBM01/CONTROLFILE


    ASMCMD [+RECO/DBM01/CONTROLFILE] > exit


    [oracle@dm01db01 ~]$ . oraenv
    ORACLE_SID = [+ASM1] ? dbm011
    The Oracle base remains unchanged with value /u01/app/oracle


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Sat May 26 08:55:09 2018


    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> alter system set control_files=’+RECO/DBM01/CONTROLFILE/current.331.977129649′ scope=spfile sid=’*’;


    System altered.


    SQL> shutdown immediate;
    ORA-01507: database not mounted




    ORACLE instance shut down.
    SQL> exit


    [oracle@dm01db01 ~]$ srvctl start database -d dbm01


    [oracle@dm01db01 ~]$ srvctl status database -d dbm01
    Instance dbm011 is running on node dm01db01
    Instance dbm012 is running on node dm01db02
    Instance dbm013 is running on node dm01db03
    Instance dbm014 is running on node dm01db04




    Step 9: Move block change tracking file to +RECO Disk Group


    SQL> select filename from v$block_change_tracking;


    FILENAME
    ——————————————————————–
    +DATA/dbm01/changetracking/ctf.282.976375227


    SQL> alter database disable block change tracking;


    Database altered.


    SQL> alter database enable block change tracking using file ‘+RECO’;


    Database altered.


    SQL> select filename from v$block_change_tracking;


    FILENAME
    ——————————————————————–
    +RECO/dbm01/changetracking/ctf.319.977128195




    Step 10: Move Flash Recovery Area to +RECO Disk Group


    SQL> show parameter recover


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_recovery_file_dest                string      +DATA


    SQL> alter system set db_recovery_file_dest=’+RECO’;


    System altered.


    SQL> show parameter db_recovery_file_dest


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_recovery_file_dest                string      +RECO




    Step 11: Update OMF parameter to point to +RECO


    SQL> show parameter online


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_create_online_log_dest_1          string      +DATA


    SQL> alter system set db_create_online_log_dest_1=’+RECO’;


    System altered.


    SQL> show parameter db_create_online_log_dest_1


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_create_online_log_dest_1          string      +RECO




    Step 12: Verify the entire database is moved to +RECO ASM Disk Group


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Sat May 26 08:57:57 2018


    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> select name, open_mode,database_role from gv$database;


    NAME      OPEN_MODE            DATABASE_ROLE
    ——— ——————– —————-
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY


    SQL> set lines 200
    SQL> set pages 200
    SQL> select name from v$tempfile;


    NAME
    ——————————————————-
    +RECO/dbm01/tempfile/temp.297.977125145


    SQL> select name from v$controlfile;


    NAME
    ——————————————————-
    +RECO/dbm01/controlfile/current.331.977129649


    SQL> select name from v$datafile;


    NAME
    ——————————————————–
    +RECO/dbm01/datafile/system.291.977121353
    +RECO/dbm01/datafile/sysaux.290.977121353
    +RECO/dbm01/datafile/undotbs1.289.977121353
    +RECO/dbm01/datafile/undotbs2.288.977121353
    +RECO/dbm01/datafile/undotbs3.287.977121353
    +RECO/dbm01/datafile/undotbs4.286.977121353
    +RECO/dbm01/datafile/users.284.977121353


    7 rows selected.


    SQL> select member from v$logfile;


    MEMBER
    ———————————————————
    +RECO/dbm01/onlinelog/group_1.298.977127719
    +RECO/dbm01/onlinelog/group_2.299.977125295
    +RECO/dbm01/onlinelog/group_3.300.977125299
    +RECO/dbm01/onlinelog/group_4.301.977125309
    +RECO/dbm01/onlinelog/group_5.302.977125313
    +RECO/dbm01/onlinelog/group_6.303.977125317
    +RECO/dbm01/onlinelog/group_7.304.977125321
    +RECO/dbm01/onlinelog/group_8.305.977125327
    +RECO/dbm01/onlinelog/group_9.306.977125329
    +RECO/dbm01/onlinelog/group_10.307.977125333
    +RECO/dbm01/onlinelog/group_11.308.977125335
    +RECO/dbm01/onlinelog/group_12.309.977125339
    +RECO/dbm01/onlinelog/group_13.310.977125343
    +RECO/dbm01/onlinelog/group_14.311.977125345
    +RECO/dbm01/onlinelog/group_15.312.977125349
    +RECO/dbm01/onlinelog/group_16.313.977125351


    16 rows selected.




    Conclusion


    In this article we have learned how to move a Database from +DATA ASM Disk Group to +RECO Disk Group. Using RMAN along with FRA makes it easy to move a database from one location to another. 

  • Extend or Increase root File System Size on Exadata

    When Exadata database machine is installed by Oracle ACS the root file system size is set to 30GB. This space may not be sufficient for storing large files, logfiles, patches and so on and it can be filled very quickly. So you must consider increasing the root file system to avoid space issues. The root file system is built on volume group which makes it easy to resize the logical volume on which the root file system is mounted.


    Root file system is created on two system partitions LVDbSys1 and LVDbSys2 and both system partitions must be size equally at the same time. Only one system partition is active at any time and other is inactive.


    In this article, we will demonstrate how you can extend/increase the root file system size on Exadata Compute node. This activity can be done online without any downtime if the file system feature supports it.


    Steps to extend/increase the root file system on Exadata Compute node


    Step 1: Get the current root file system size and utilization. Here we can see that the root file system was expanded early to 60GB and currently it is 100% used.


    [root@dm01db01 /]# df -h /
    Filesystem            Size  Used Avail Use% Mounted on
    /dev/mapper/VGExaDb-LVDbSys1
                           59G   57G     0 100% /


    Step 2: Get the logical volumne details


    [root@dm01db01 /]# lvs -o lv_name,lv_path,vg_name,lv_size
      LV                 Path                            VG      LSize
      LVDbOra1           /dev/VGExaDb/LVDbOra1           VGExaDb 200.00g
      LVDbSwap1          /dev/VGExaDb/LVDbSwap1          VGExaDb  24.00g
      LVDbSys1           /dev/VGExaDb/LVDbSys1           VGExaDb  60.00g
      LVDbSys2           /dev/VGExaDb/LVDbSys2           VGExaDb  60.00g
      LVDoNotRemoveOrUse /dev/VGExaDb/LVDoNotRemoveOrUse VGExaDb   1.00g


    Step 3: Check to make sure that root file system can be resized online. Execute the following to determine it. If you get an output the file system can be resized online

    [root@dm01db01 /]# tune2fs -l /dev/mapper/VGExaDb-LVDbSys1 | grep resize_inode
    Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize


    [root@dm01db01 /]# dcli -g ~/dbs_group -l root ‘tune2fs -l /dev/mapper/VGExaDb-LVDbSys1 | grep resize_inode’
    dm01db01: Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
    dm01db02: Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
    dm01db03: Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize
    dm01db04: Filesystem features:      has_journal ext_attr resize_inode dir_index filetype needs_recovery extent flex_bg sparse_super large_file huge_file uninit_bg dir_nlink extra_isize


    Step 4: Get the current active partition information. Here the current active partition is LVDbSys1


    [root@dm01db01 ~]# imageinfo


    Kernel version: 4.1.12-94.7.8.el6uek.x86_64 #2 SMP Thu Jan 11 20:41:01 PST 2018 x86_64
    Image kernel version: 4.1.12-94.7.8.el6uek
    Image version: 12.2.1.1.6.180125.1
    Image activated: 2018-04-13 22:11:49 -0500
    Image status: success
    System partition on device: /dev/mapper/VGExaDb-LVDbSys1




    Step 5: Get the free space available in the Volume Group. Currently we have around 1.3TB free space available. So we can easily increase the root file system.


    [root@dm01db01 /]# vgdisplay -s
      “VGExaDb” 1.63 TiB  [345.00 GiB used / 1.30 TiB free]


    Step 6: Using lvextend command increase the both logical volumes. In our case, we are increasing the root file system by 30GB to make 90GB total size.


    [root@dm01db01 /]# lvextend -L +30G /dev/VGExaDb/LVDbSys1
      Size of logical volume VGExaDb/LVDbSys1 changed from 60.00 GiB (15360 extents) to 90.00 GiB (23040 extents).
      Logical volume LVDbSys1 successfully resized.


    [root@dm01db01 /]# lvextend -L +30G /dev/VGExaDb/LVDbSys2
      Size of logical volume VGExaDb/LVDbSys2 changed from 60.00 GiB (15360 extents) to 90.00 GiB (23040 extents).
      Logical volume LVDbSys2 successfully resized.


    Step 7: Using resize2fs command resize the file system as follows


    [root@dm01db01 /]# resize2fs /dev/VGExaDb/LVDbSys1
    resize2fs 1.43-WIP (20-Jun-2013)
    Filesystem at /dev/VGExaDb/LVDbSys1 is mounted on /; on-line resizing required
    old_desc_blocks = 4, new_desc_blocks = 6
    The filesystem on /dev/VGExaDb/LVDbSys1 is now 23592960 blocks long.


    [root@dm01db01 /]# e2fsck -f /dev/VGExaDb/LVDbSys1
    e2fsck 1.43-WIP (20-Jun-2013)
    /dev/VGExaDb/LVDbSys1 is mounted.
    e2fsck: Cannot continue, aborting.




    [root@dm01db01 /]# resize2fs /dev/VGExaDb/LVDbSys2
    resize2fs 1.43-WIP (20-Jun-2013)
    Please run ‘e2fsck -f /dev/VGExaDb/LVDbSys2’ first.


    [root@dm01db01 /]# e2fsck -f /dev/VGExaDb/LVDbSys2
    e2fsck 1.43-WIP (20-Jun-2013)
    Pass 1: Checking inodes, blocks, and sizes
    Pass 2: Checking directory structure
    Pass 3: Checking directory connectivity
    Pass 4: Checking reference counts
    Pass 5: Checking group summary information
    /dev/VGExaDb/LVDbSys2: 167407/3932160 files (0.1% non-contiguous), 4710754/15728640 blocks


    [root@dm01db01 /]# resize2fs /dev/VGExaDb/LVDbSys2
    resize2fs 1.43-WIP (20-Jun-2013)
    Resizing the filesystem on /dev/VGExaDb/LVDbSys2 to 23592960 (4k) blocks.
    The filesystem on /dev/VGExaDb/LVDbSys2 is now 23592960 blocks long.


    Note: You can’t run the e2fsck for the active paritition LVDbSys1. You run the e2fsck for inactive partition LVDbSys2 first before resizing it.


    Step 8: Verify the new file system size


    [root@dm01db01 /]# df -h /
    Filesystem            Size  Used Avail Use% Mounted on
    /dev/mapper/VGExaDb-LVDbSys1
                           89G   57G   29G  67% /


    Repeat the steps above on all the compute nodes in the Exadata Rack.




    Conclusion


    In this article we have learned how to extend/increase the root file system on Exadata Compute node online without any outage. Root file system is created on two system partitions LVDbSys1 and LVDbSys2 and both system partitions must be size equally at the same time. Only one system partition is active at any time and other is inactive.

  • Rename Oracle ASM Disk Group On Exadata

    When Oracle ACS build Exadata Database Machine, they use the OEDA file that you sent them over for Exadata Install. The Exadata is built with default ASM Disk Group name DATAC1, RECOC1 & DBFS_DG. If you want to rename the DATAC1 and RECOC1 to something different to match your Organization standards you can do that by using the Oracle renamedg utility. The number Database version required to rename an ASM Disk Group is 11.2.


    In this article we will demonstrate how to rename ASM Disk Group on Exadata Database Machine running Oracle Database 11.2


    Here we want to change the following ASM Disk Group Names:
    DATAC1 to DATA
    RECOC1 to RECO


    Steps to rename ASM Disk Group


    • Get the Database version

    ORACLE_SID = [+ASM1] ? dbm011
    The Oracle base remains unchanged with value /u01/app/oracle


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Thu May 24 16:36:34 2018
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> select * from v$version;


    BANNER
    ——————————————————————————–
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    PL/SQL Release 11.2.0.4.0 – Production
    CORE    11.2.0.4.0      Production
    TNS for Linux: Version 11.2.0.4.0 – Production
    NLSRTL Version 11.2.0.4.0 – Production

    • Connect to asmcmd and make a note of the Disk Group Names

    [oracle@dm01db01 ~]$ . oraenv


    ORACLE_SID = [oracle] ? +ASM1
    The Oracle base has been set to /u01/app/oracle


    [oracle@dm01db01 ~]$ asmcmd -p


    ASMCMD [+] > lsdg
    State    Type    Rebal  Sector  Block       AU   Total_MB    Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH    N         512   4096  4194304  272154624  271558968          6479872        88359698              0             N  DATAC1/
    MOUNTED  HIGH    N         512   4096  4194304    2404640    2402468            68704          777921              0             Y  DBFS_DG/
    MOUNTED  NORMAL  N         512   4096  4194304   45389568   45386648           540352        22423148              0             N  RECOC1/

    • Check the versions

    ASMCMD [+] > lsct
    DB_Name  Status     Software_Version  Compatible_version  Instance_Name  Disk_Group
    +ASM     CONNECTED        11.2.0.4.0          11.2.0.4.0  +ASM1          DBFS_DG
    DBM01    CONNECTED        11.2.0.4.0          11.2.0.4.0  dbm011         DATAC1

    • Check the database status

    [oracle@dm01db01 ~]$ srvctl status database -d dbm01
    Instance dbm011 is running on node dm01db01
    Instance dbm012 is running on node dm01db02
    Instance dbm013 is running on node dm01db03
    Instance dbm014 is running on node dm01db04

    • Make a note of the control files, Datafiles, Redo logfiles before stopping the database.

    SQL> select name from v$controlfile;
    SQL> select name from v$datafile;
    SQL> select member from v$logfile;
    SQL> select * from v$block_change_tracking;

    • Stop database database

    [oracle@dm01db01 ~]$ srvctl stop database -d dbm01


    [oracle@dm01db01 ~]$ srvctl status database -d dbm01
    Instance dbm011 is not running on node dm01db01
    Instance dbm012 is not running on node dm01db02
    Instance dbm013 is not running on node dm01db03
    Instance dbm014 is not running on node dm01db04

    • Umount the ASM disk group(s) that you want to rename. Connect to ASM command prompt and umount the disk group. umount the disk group from all nodes.

    ASMCMD [+] > umount DATAC1


    ASMCMD [+] > umount RECOC1


    ASMCMD [+] > lsdg
    State    Type  Rebal  Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH  N         512   4096  4194304   2404640  2402468            68704          777921              0             Y  DBFS_DG/


    Note: If you don’t stop the databases using ASM disk group you will get the following error message:


    ASMCMD [+] > umount DATAC1
    ORA-15032: not all alterations performed
    ORA-15027: active use of diskgroup “DATAC1” precludes its dismount (DBD ERROR: OCIStmtExecute)


    *** Repeat the above steps on all the remaining nodes in the Cluster***


    [oracle@dm01db01 ~]$ ssh dm01db02
    Last login: Thu May 17 15:23:31 2018 from dm01db01


    [oracle@dm01db02 ~]$ . oraenv
    ORACLE_SID = [oracle] ? +ASM2
    The Oracle base has been set to /u01/app/oracle


    [oracle@dm01db02 ~]$ asmcmd lsdg
    State    Type    Rebal  Sector  Block       AU   Total_MB    Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH    N         512   4096  4194304  272154624  271558968          6479872        88359698              0             N  DATAC1/
    MOUNTED  HIGH    N         512   4096  4194304    2404640    2402468            68704          777921              0             Y  DBFS_DG/
    MOUNTED  NORMAL  N         512   4096  4194304   45389568   45385040           540352        22422344              0             N  RECOC1/


    [oracle@dm01db02 ~]$ asmcmd umount DATAC1


    [oracle@dm01db02 ~]$ asmcmd umount RECOC1


    [oracle@dm01db02 ~]$ asmcmd lsdg
    State    Type  Rebal  Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH  N         512   4096  4194304   2404640  2402468            68704          777921              0             Y  DBFS_DG/


    [oracle@dm01db01 ~]$ ssh dm01db03
    Last login: Thu May 17 15:23:31 2018 from dm01db01


    [oracle@dm01db03 ~]$ . oraenv
    ORACLE_SID = [oracle] ? +ASM3
    The Oracle base has been set to /u01/app/oracle


    [oracle@dm01db03 ~]$ asmcmd umount DATAC1


    [oracle@dm01db03 ~]$ asmcmd umount RECOC1


    [oracle@dm01db03 ~]$ asmcmd lsdg
    State    Type  Rebal  Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH  N         512   4096  4194304   2404640  2402468            68704          777921              0             Y  DBFS_DG/


    [oracle@dm01db01 ~]$ ssh dm01db04
    Last login: Thu May 17 15:23:31 2018 from dm01db01


    [oracle@dm01db04 ~]$ . oraenv
    ORACLE_SID = [oracle] ? +ASM4
    The Oracle base has been set to /u01/app/oracle


    [oracle@dm01db04 ~]$ asmcmd umount DATAC1


    [oracle@dm01db04 ~]$ asmcmd umount RECOC1


    [oracle@dm01db04 ~]$ asmcmd lsdg
    State    Type  Rebal  Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH  N         512   4096  4194304   2404640  2402468            68704          777921              0             Y  DBFS_DG/

    • Verify that renamedg is in PATH

    [oracle@dm01db01 ~]$ which renamedg
    /u01/app/11.2.0.4/grid/bin/renamedg

    • As owner of the Grid Infrastruture software execute the renamdg command. Here the owner of GI home is ‘oracle’ user. First I am renaming DATAC1 disk group to DATA

    [oracle@dm01db01 ~]$ renamedg phase=both dgname=DATAC1 newdgname=DATA verbose=true


    NOTE: No asm libraries found in the system
    Parsing parameters..
    Parameters in effect:


             Old DG name       : DATAC1
             New DG name       : DATA
             Phases            :
                     Phase 1
                     Phase 2
             Discovery str      : (null)
             Clean              : TRUE
             Raw only           : TRUE
    renamedg operation: phase=both dgname=DATAC1 newdgname=DATA verbose=true
    Executing phase 1
    Discovering the group
    Performing discovery with string:
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_02_dm01cel01 with disk number:74 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_11_dm01cel01 with disk number:83 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_07_dm01cel01 with disk number:79 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_04_dm01cel01 with disk number:76 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_05_dm01cel01 with disk number:77 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_10_dm01cel01 with disk number:82 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_06_dm01cel01 with disk number:78 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_03_dm01cel01 with disk number:75 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_00_dm01cel01 with disk number:72 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_08_dm01cel01 with disk number:80 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_01_dm01cel01 with disk number:73 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_09_dm01cel01 with disk number:81 and timestamp (33068591 612262912)



    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_09_dm01cel07 with disk number:69 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_03_dm01cel07 with disk number:63 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_06_dm01cel07 with disk number:66 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_08_dm01cel07 with disk number:68 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_04_dm01cel07 with disk number:64 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_07_dm01cel07 with disk number:67 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_01_dm01cel07 with disk number:61 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_05_dm01cel07 with disk number:65 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_02_dm01cel07 with disk number:62 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_00_dm01cel07 with disk number:60 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_11_dm01cel07 with disk number:71 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_10_dm01cel07 with disk number:70 and timestamp (33068591 612262912)
    Checking for hearbeat…
    Re-discovering the group
    Performing discovery with string:
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_02_dm01cel01 with disk number:74 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_11_dm01cel01 with disk number:83 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_07_dm01cel01 with disk number:79 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_04_dm01cel01 with disk number:76 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_05_dm01cel01 with disk number:77 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_10_dm01cel01 with disk number:82 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_06_dm01cel01 with disk number:78 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_03_dm01cel01 with disk number:75 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_00_dm01cel01 with disk number:72 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_08_dm01cel01 with disk number:80 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_01_dm01cel01 with disk number:73 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/DATAC1_CD_09_dm01cel01 with disk number:81 and timestamp (33068591 612262912)



    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_09_dm01cel07 with disk number:69 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_03_dm01cel07 with disk number:63 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_06_dm01cel07 with disk number:66 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_08_dm01cel07 with disk number:68 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_04_dm01cel07 with disk number:64 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_07_dm01cel07 with disk number:67 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_01_dm01cel07 with disk number:61 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_05_dm01cel07 with disk number:65 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_02_dm01cel07 with disk number:62 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_00_dm01cel07 with disk number:60 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_11_dm01cel07 with disk number:71 and timestamp (33068591 612262912)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/DATAC1_CD_10_dm01cel07 with disk number:70 and timestamp (33068591 612262912)
    Checking if the diskgroup is mounted or used by CSS
    Checking disk number:74
    Checking disk number:83
    Checking disk number:79
    Checking disk number:76
    Checking disk number:77
    Checking disk number:82
    Checking disk number:78
    Checking disk number:75
    Checking disk number:72
    Checking disk number:80
    Checking disk number:73
    Checking disk number:81
    Checking disk number:69
    Checking disk number:63
    Checking disk number:66
    Checking disk number:68
    Checking disk number:64
    Checking disk number:67
    Checking disk number:61
    Checking disk number:65
    Checking disk number:62
    Checking disk number:60


    Generating configuration file..
    Completed phase 1
    Executing phase 2
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_02_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_11_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_07_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_04_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_05_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_10_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_06_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_03_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_00_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_08_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/DATAC1_CD_01_dm01cel01
    Modifying the header


    Modifying the header
    Completed phase 2
    Terminating kgfd context 0x7f9d346240a0

    • Now rename RECOC1 ASM disk group to RECO using renamdg command

    [oracle@dm01db01 ~]$ renamedg phase=both dgname=RECOC1 newdgname=RECO verbose=true


    NOTE: No asm libraries found in the system
    Parsing parameters..
    Parameters in effect:


             Old DG name       : RECOC1
             New DG name       : RECO
             Phases            :
                     Phase 1
                     Phase 2
             Discovery str      : (null)
             Clean              : TRUE
             Raw only           : TRUE
    renamedg operation: phase=both dgname=RECOC1 newdgname=RECO verbose=true
    Executing phase 1
    Discovering the group
    Performing discovery with string:
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_03_dm01cel01 with disk number:75 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_04_dm01cel01 with disk number:76 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_05_dm01cel01 with disk number:77 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_00_dm01cel01 with disk number:72 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_10_dm01cel01 with disk number:82 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_07_dm01cel01 with disk number:79 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_02_dm01cel01 with disk number:74 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_01_dm01cel01 with disk number:73 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_11_dm01cel01 with disk number:83 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_08_dm01cel01 with disk number:80 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_09_dm01cel01 with disk number:81 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_06_dm01cel01 with disk number:78 and timestamp (33068591 628813824)


    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_01_dm01cel07 with disk number:61 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_08_dm01cel07 with disk number:68 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_06_dm01cel07 with disk number:66 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_11_dm01cel07 with disk number:71 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_10_dm01cel07 with disk number:70 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_05_dm01cel07 with disk number:65 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_00_dm01cel07 with disk number:60 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_03_dm01cel07 with disk number:63 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_09_dm01cel07 with disk number:69 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_07_dm01cel07 with disk number:67 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_02_dm01cel07 with disk number:62 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_04_dm01cel07 with disk number:64 and timestamp (33068591 628813824)
    Checking for hearbeat…
    Re-discovering the group
    Performing discovery with string:
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_03_dm01cel01 with disk number:75 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_04_dm01cel01 with disk number:76 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_05_dm01cel01 with disk number:77 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_00_dm01cel01 with disk number:72 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_10_dm01cel01 with disk number:82 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_07_dm01cel01 with disk number:79 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_02_dm01cel01 with disk number:74 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_01_dm01cel01 with disk number:73 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_11_dm01cel01 with disk number:83 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_08_dm01cel01 with disk number:80 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_09_dm01cel01 with disk number:81 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.9;192.168.10.10/RECOC1_CD_06_dm01cel01 with disk number:78 and timestamp (33068591 628813824)


    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_01_dm01cel07 with disk number:61 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_08_dm01cel07 with disk number:68 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_06_dm01cel07 with disk number:66 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_11_dm01cel07 with disk number:71 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_10_dm01cel07 with disk number:70 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_05_dm01cel07 with disk number:65 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_00_dm01cel07 with disk number:60 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_03_dm01cel07 with disk number:63 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_09_dm01cel07 with disk number:69 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_07_dm01cel07 with disk number:67 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_02_dm01cel07 with disk number:62 and timestamp (33068591 628813824)
    Identified disk OSS::o/192.168.10.21;192.168.10.22/RECOC1_CD_04_dm01cel07 with disk number:64 and timestamp (33068591 628813824)


    Checking if the diskgroup is mounted or used by CSS
    Checking disk number:75
    Checking disk number:76
    Checking disk number:77
    Checking disk number:72
    Checking disk number:82
    Checking disk number:79
    Checking disk number:74
    Checking disk number:73
    Checking disk number:83
    Checking disk number:80
    Checking disk number:81
    Checking disk number:78
    Checking disk number:61
    Checking disk number:68
    Checking disk number:66
    Checking disk number:71
    Checking disk number:70
    Checking disk number:65
    Checking disk number:60
    Checking disk number:63
    Checking disk number:69
    Checking disk number:67
    Checking disk number:62
    Checking disk number:64
    Checking disk number:49


    Generating configuration file..
    Completed phase 1
    Executing phase 2
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_03_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_04_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_05_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_00_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_10_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_07_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_02_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_01_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_11_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_08_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_09_dm01cel01
    Modifying the header
    Looking for o/192.168.10.9;192.168.10.10/RECOC1_CD_06_dm01cel01
    Modifying the header


    Modifying the header
    Completed phase 2
    Terminating kgfd context 0x7f8d42f6c0a0

    • Mount the DATA and RECO ASM disk groups on all the nodes.

    [oracle@dm01db01 ~]$ asmcmd -p


    ASMCMD [+] > lsdg
    State    Type  Rebal  Sector  Block       AU  Total_MB  Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH  N         512   4096  4194304   2404640  2402468            68704          777921              0             Y  DBFS_DG/


    ASMCMD [+] > mount DATA


    ASMCMD [+] > mount RECO


    ASMCMD [+] > lsdg
    State    Type    Rebal  Sector  Block       AU   Total_MB    Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH    N         512   4096  4194304  272154624  271558968          6479872        88359698              0             N  DATA/
    MOUNTED  HIGH    N         512   4096  4194304    2404640    2402468            68704          777921              0             Y  DBFS_DG/
    MOUNTED  NORMAL  N         512   4096  4194304   45389568   45385040           540352        22422344              0             N  RECO/


    *** Repeat the above steps on all the remaning compute nodes in the Cluster***


    Note: 

    • renamedg utility cannot rename the associated ASM/Grid disk disk name
    • renamedg utility cannot rename/update the control files, datafiles, redo log files and any other files that reference ASM DG for all databases



    Steps to rename control files, datafiles, redo log files and other database files


    • Update SPFILE location

    [oracle@dm01db01 ~]$ cd $ORACLE_HOME/dbs


    [oracle@dm01db01 dbs]$ cat initdbm011.ora
    SPFILE=’+DATAC1/dbm01/spfiledbm01.ora’


    [oracle@dm01db01 dbs]$ vi initdbm011.ora


    [oracle@dm01db01 dbs]$ cat initdbm011.ora
    SPFILE=’+DATA/dbm01/spfiledbm01.ora’


    [oracle@dm01db01 dbs]$ scp initdbm011.ora dm01db02:/u01/app/oracle/product/11.2.0.4/dbhome/dbs/initdbm012.ora
    initdbm011.ora                                                                                                                                             100%   42     0.0KB/s   00:00


    [oracle@dm01db01 dbs]$ scp initdbm011.ora dm01db03:/u01/app/oracle/product/11.2.0.4/dbhome/dbs/initdbm013.ora
    initdbm011.ora                                                                                                                                             100%   42     0.0KB/s   00:00


    [oracle@dm01db01 dbs]$ scp initdbm011.ora dm01db04:/u01/app/oracle/product/11.2.0.4/dbhome/dbs/initdbm014.ora
    initdbm011.ora                                                                                                                                             100%   42     0.0KB/s   00:00

    • Update control file location

    [oracle@dm01db01 dbs]$ . oraenv
    ORACLE_SID = [dbm011] ?
    The Oracle base remains unchanged with value /u01/app/oracle


    [oracle@dm01db01 dbs]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Fri May 25 10:17:49 2018
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.
    Connected to an idle instance.


    SQL> startup nomount;
    ORACLE instance started.


    Total System Global Area 2.5655E+10 bytes
    Fixed Size                  2265224 bytes
    Variable Size            4160753528 bytes
    Database Buffers         2.1341E+10 bytes
    Redo Buffers              151113728 bytes


    SQL> show parameter control_files


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    control_files                        string      +DATAC1/dbm01/controlfile/current.256.976374731


    SQL> alter system set control_files=’+DATA/dbm01/controlfile/current.256.976374731′ scope=spfile;


    System altered.


    SQL> shutdown immediate;
    ORA-01507: database not mounted




    ORACLE instance shut down.
    SQL> startup mount
    ORACLE instance started.


    Total System Global Area 2.5655E+10 bytes
    Fixed Size                  2265224 bytes
    Variable Size            4160753528 bytes
    Database Buffers         2.1341E+10 bytes
    Redo Buffers              151113728 bytes
    Database mounted.


    SQL> select name from v$controlfile;


    NAME
    ——————————————————————————–
    +DATA/dbm01/controlfile/current.256.976374731

    • Update datafile and redo log file locations

    SQL> select name from v$datafile;


    NAME
    ——————————————————————————–
    +DATAC1/dbm01/datafile/system.259.976374739
    +DATAC1/dbm01/datafile/sysaux.260.976374743
    +DATAC1/dbm01/datafile/undotbs1.261.976374745
    +DATAC1/dbm01/datafile/undotbs2.263.976374753
    +DATAC1/dbm01/datafile/undotbs3.264.976374755
    +DATAC1/dbm01/datafile/undotbs4.265.976374757
    +DATAC1/dbm01/datafile/users.266.976374757


    7 rows selected.


    SQL> select member from v$logfile;


    MEMBER
    ——————————————————————————–
    +DATAC1/dbm01/onlinelog/group_1.257.976374733
    +DATAC1/dbm01/onlinelog/group_2.258.976374735
    +DATAC1/dbm01/onlinelog/group_7.267.976375073
    +DATAC1/dbm01/onlinelog/group_8.268.976375075
    +DATAC1/dbm01/onlinelog/group_5.269.976375079
    +DATAC1/dbm01/onlinelog/group_6.270.976375083
    +DATAC1/dbm01/onlinelog/group_3.271.976375085
    +DATAC1/dbm01/onlinelog/group_4.272.976375087
    +DATAC1/dbm01/onlinelog/group_9.274.976375205
    +DATAC1/dbm01/onlinelog/group_10.275.976375209
    +DATAC1/dbm01/onlinelog/group_11.276.976375211
    +DATAC1/dbm01/onlinelog/group_12.277.976375215
    +DATAC1/dbm01/onlinelog/group_13.278.976375217
    +DATAC1/dbm01/onlinelog/group_14.279.976375219
    +DATAC1/dbm01/onlinelog/group_15.280.976375223
    +DATAC1/dbm01/onlinelog/group_16.281.976375225


    16 rows selected.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/system.259.976374739’ to ‘+DATA/dbm01/datafile/system.259.976374739’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/sysaux.260.976374743’ to ‘+DATA/dbm01/datafile/sysaux.260.976374743’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/undotbs1.261.976374745’ to ‘+DATA/dbm01/datafile/undotbs1.261.976374745’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/undotbs2.263.976374753’ to ‘+DATA/dbm01/datafile/undotbs2.263.976374753’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/undotbs3.264.976374755’ to ‘+DATA/dbm01/datafile/undotbs3.264.976374755’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/undotbs4.265.976374757’ to ‘+DATA/dbm01/datafile/undotbs4.265.976374757’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/datafile/users.266.976374757’ to ‘+DATA/dbm01/datafile/users.266.976374757’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_1.257.976374733’  to ‘+DATA/dbm01/onlinelog/group_1.257.976374733’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_2.258.976374735’  to ‘+DATA/dbm01/onlinelog/group_2.258.976374735’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_7.267.976375073’  to ‘+DATA/dbm01/onlinelog/group_7.267.976375073’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_8.268.976375075’  to ‘+DATA/dbm01/onlinelog/group_8.268.976375075’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_5.269.976375079’  to ‘+DATA/dbm01/onlinelog/group_5.269.976375079’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_6.270.976375083’  to ‘+DATA/dbm01/onlinelog/group_6.270.976375083’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_3.271.976375085’  to ‘+DATA/dbm01/onlinelog/group_3.271.976375085’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_4.272.976375087’  to ‘+DATA/dbm01/onlinelog/group_4.272.976375087’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_9.274.976375205’  to ‘+DATA/dbm01/onlinelog/group_9.274.976375205’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_10.275.976375209’ to ‘+DATA/dbm01/onlinelog/group_10.275.976375209’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_11.276.976375211’ to ‘+DATA/dbm01/onlinelog/group_11.276.976375211’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_12.277.976375215’ to ‘+DATA/dbm01/onlinelog/group_12.277.976375215’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_13.278.976375217’ to ‘+DATA/dbm01/onlinelog/group_13.278.976375217’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_14.279.976375219’ to ‘+DATA/dbm01/onlinelog/group_14.279.976375219’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_15.280.976375223’ to ‘+DATA/dbm01/onlinelog/group_15.280.976375223’;


    Database altered.


    SQL> alter database rename file ‘+DATAC1/dbm01/onlinelog/group_16.281.976375225’ to ‘+DATA/dbm01/onlinelog/group_16.281.976375225’;


    Database altered.

    • Verify the datafiles and redo log files names

    SQL> select name from v$datafile;


    NAME
    ——————————————————————————–
    +DATA/dbm01/datafile/system.259.976374739
    +DATA/dbm01/datafile/sysaux.260.976374743
    +DATA/dbm01/datafile/undotbs1.261.976374745
    +DATA/dbm01/datafile/undotbs2.263.976374753
    +DATA/dbm01/datafile/undotbs3.264.976374755
    +DATA/dbm01/datafile/undotbs4.265.976374757
    +DATA/dbm01/datafile/users.266.976374757


    7 rows selected.


    SQL> select member from v$logfile;


    MEMBER
    ——————————————————————————–
    +DATA/dbm01/onlinelog/group_1.257.976374733
    +DATA/dbm01/onlinelog/group_2.258.976374735
    +DATA/dbm01/onlinelog/group_7.267.976375073
    +DATA/dbm01/onlinelog/group_8.268.976375075
    +DATA/dbm01/onlinelog/group_5.269.976375079
    +DATA/dbm01/onlinelog/group_6.270.976375083
    +DATA/dbm01/onlinelog/group_3.271.976375085
    +DATA/dbm01/onlinelog/group_4.272.976375087
    +DATA/dbm01/onlinelog/group_9.274.976375205
    +DATA/dbm01/onlinelog/group_10.275.976375209
    +DATA/dbm01/onlinelog/group_11.276.976375211
    +DATA/dbm01/onlinelog/group_12.277.976375215
    +DATA/dbm01/onlinelog/group_13.278.976375217
    +DATA/dbm01/onlinelog/group_14.279.976375219
    +DATA/dbm01/onlinelog/group_15.280.976375223
    +DATA/dbm01/onlinelog/group_16.281.976375225


    16 rows selected.

    • Update block change tracking file location

    SQL> alter database rename file ‘+DATAC1/dbm01/changetracking/ctf.282.976375227’ to ‘+DATA/dbm01/changetracking/ctf.282.976375227’;


    Database altered.


    SQL> select * from v$block_change_tracking;


    STATUS
    ———-
    FILENAME
    ——————————————————————————–
         BYTES
    ———-
    ENABLED
    +DATA/dbm01/changetracking/ctf.282.976375227
      11599872

    • Update OMF related parameters

    SQL> show parameter db_create_online_log_dest_1


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_create_online_log_dest_1          string      +DATAC1


    SQL> alter system set db_create_online_log_dest_1=’+DATA’;


    System altered.


    SQL> show parameter db_create_online_log_dest_1


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_create_online_log_dest_1          string      +DATA

    • Update Fast Recovery Area location

    SQL> show parameter db_recovery_file_dest


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_recovery_file_dest                string      +RECOC1
    db_recovery_file_dest_size           big integer 20425000M


    SQL> alter system set db_recovery_file_dest=’+RECO’;


    System altered.


    SQL> show parameter db_recovery_file_dest


    NAME                                 TYPE        VALUE
    ———————————— ———– ——————————
    db_recovery_file_dest                string      +RECO
    db_recovery_file_dest_size           big integer 20425000M

    • Shutdown the database

    SQL> shutdown immediate;
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> exit

    • Update the database configuration

    [oracle@dm01db01 dbs]$ srvctl config database -d dbm01
    Database unique name: dbm01
    Database name: dbm01
    Oracle home: /u01/app/oracle/product/11.2.0.4/dbhome
    Oracle user: oracle
    Spfile: +DATAC1/dbm01/spfiledbm01.ora
    Domain:
    Start options: open
    Stop options: immediate
    Database role: PRIMARY
    Management policy: AUTOMATIC
    Server pools: dbm01
    Database instances: dbm011,dbm012,dbm013,dbm014
    Disk Groups: DATAC1,RECOC1,DATA
    Mount point paths:
    Services:
    Type: RAC
    Database is administrator managed


    [oracle@dm01db01 dbs]$ srvctl modify database -p +DATA/dbm01/spfiledbm01.ora -a DATA,RECO -d dbm01


    [oracle@dm01db01 dbs]$ srvctl config database -d dbm01
    Database unique name: dbm01
    Database name: dbm01
    Oracle home: /u01/app/oracle/product/11.2.0.4/dbhome
    Oracle user: oracle
    Spfile: +DATA/dbm01/spfiledbm01.ora
    Domain:
    Start options: open
    Stop options: immediate
    Database role: PRIMARY
    Management policy: AUTOMATIC
    Server pools: dbm01
    Database instances: dbm011,dbm012,dbm013,dbm014
    Disk Groups: DATA,RECO
    Mount point paths:
    Services:
    Type: RAC
    Database is administrator managed

    • Start the database and verify

    [oracle@dm01db01 dbs]$ srvctl start database -d dbm01


    [oracle@dm01db01 dbs]$ srvctl status database -d dbm01
    Instance dbm011 is running on node dm01db01
    Instance dbm012 is running on node dm01db02
    Instance dbm013 is running on node dm01db03
    Instance dbm014 is running on node dm01db04


    [oracle@dm01db01 dbs]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Fri May 25 10:40:34 2018
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> select name, open_mode,database_role from gv$database;


    NAME      OPEN_MODE            DATABASE_ROLE
    ——— ——————– —————-
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY
    DBM01     READ WRITE           PRIMARY


    ORACLE_SID = [+ASM1] ? dbm011
    The Oracle base remains unchanged with value /u01/app/oracle


    [oracle@dm01db01 ~]$ sqlplus / as sysdba


    SQL*Plus: Release 11.2.0.4.0 Production on Thu May 24 16:36:34 2018
    Copyright (c) 1982, 2013, Oracle.  All rights reserved.


    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options


    SQL> select * from v$version;


    BANNER
    ——————————————————————————–
    Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 – 64bit Production
    PL/SQL Release 11.2.0.4.0 – Production
    CORE    11.2.0.4.0      Production
    TNS for Linux: Version 11.2.0.4.0 – Production
    NLSRTL Version 11.2.0.4.0 – Production




    [oracle@dm01db01 ~]$ . oraenv


    ORACLE_SID = [oracle] ? +ASM1
    The Oracle base has been set to /u01/app/oracle


    [oracle@dm01db01 ~]$ asmcmd -p


    ASMCMD [+] > lsdg
    State    Type    Rebal  Sector  Block       AU   Total_MB    Free_MB  Req_mir_free_MB  Usable_file_MB  Offline_disks  Voting_files  Name
    MOUNTED  HIGH    N         512   4096  4194304  272154624  271558968          6479872        88359698              0             N  DATAC1/
    MOUNTED  HIGH    N         512   4096  4194304    2404640    2402468            68704          777921              0             Y  DBFS_DG/
    MOUNTED  NORMAL  N         512   4096  4194304   45389568   45386648           540352        22423148              0             N  RECOC1/


    ASMCMD [+] > lsct
    DB_Name  Status     Software_Version  Compatible_version  Instance_Name  Disk_Group
    +ASM     CONNECTED        11.2.0.4.0          11.2.0.4.0  +ASM1          DBFS_DG
    DBM01    CONNECTED        11.2.0.4.0          11.2.0.4.0  dbm011         DATAC1


    [oracle@dm01db01 ~]$ srvctl status database -d dbm01
    Instance dbm011 is running on node dm01db01
    Instance dbm012 is running on node dm01db02
    Instance dbm013 is running on node dm01db03
    Instance dbm014 is running on node dm01db04




    Conclusion


    In this article we have learned how to rename an ASM Disk group on Exadata running Oracle Database 11.2. Starting with Oracle Database 11.2 you can use the renamedg command to rename an ASM Disk Group. renamedg utility cannot rename the associated ASM/Grid disk disk name. Also renamedg cannot rename/update the control files, datafiles, redo log files and any other files that reference ASM DG for all databases. You must update database files manually after renaming ASM disk groups.

  • Exadata Setup SSH Equivalence

    You want to execute Operating System or Exadata commands on multiple Exadata Compute nodes and Storage Cell in parallel. To accomplish this you must setup passwordless SSH across compute nodes and storage cells.


    If SSH equivalence is NOT setup and you execute the dcli command you will see the follow messages. This mean the SSH equivalence is not configured.


    [root@dm01db01 ~]# dcli -g dbs_group -l root ‘uptime’
    The authenticity of host ‘dm01db03 (10.10.10.195)’ can’t be established.
    RSA key fingerprint is 40:81:3c:6d:ef:e7:1f:d7:a0:df:eb:f5:ea:92:a5:db.
    Are you sure you want to continue connecting (yes/no)? The authenticity of host ‘dm01db05 (10.10.10.197)’ can’t be established.
    RSA key fingerprint is 1b:95:47:0b:92:b4:13:9f:55:b7:a3:2a:56:27:9f:1c.
    Are you sure you want to continue connecting (yes/no)? The authenticity of host ‘dm01db02 (10.10.10.194)’ can’t be established.
    RSA key fingerprint is e1:0d:90:46:16:88:74:01:02:5a:11:90:63:b1:6b:1c.
    Are you sure you want to continue connecting (yes/no)? The authenticity of host ‘dm01db01 (10.10.10.193)’ can’t be established.
    RSA key fingerprint is 2b:6f:43:4b:86:29:bb:ed:a6:03:c5:34:75:cf:45:34.
    Are you sure you want to continue connecting (yes/no)? The authenticity of host ‘dm01db04 (10.10.10.196)’ can’t be established.
    RSA key fingerprint is 44:a7:ad:65:c3:1c:fb:0b:0b:28:2c:b6:a5:f3:59:99.
    Are you sure you want to continue connecting (yes/no)? The authenticity of host ‘dm01db07 (10.10.10.199)’ can’t be established.
    RSA key fingerprint is 25:5f:9a:e6:a4:7a:13:ba:e2:e7:7d:2e:79:53:49:2b.
    Are you sure you want to continue connecting (yes/no)? root@dm01db06’s password: root@dm01db08’s password:


    In this article we will demonstrate how to setup SSH equivalence on Exadata Database Machine.




    Steps to Setup SSH Equivalence


    1. Create the following files if doesn’t exist


    [root@dm01db08 ~]# cat dbs_group
    dm01db01
    dm01db02
    dm01db03
    dm01db04
    dm01db05
    dm01db06
    dm01db07
    dm01db08


    [root@dm01db08 ~]# cat cell_group
    dm01cel01
    dm01cel02
    dm01cel03
    dm01cel04
    dm01cel05
    dm01cel06
    dm01cel07


    [root@dm01db08 ~]# cat all_group
    dm01db01
    dm01db02
    dm01db03
    dm01db04
    dm01db05
    dm01db06
    dm01db07
    dm01db08
    dm01cel01
    dm01cel02
    dm01cel03
    dm01cel04
    dm01cel05
    dm01cel06
    dm01cel07
    dm01sw-iba01
    dm01sw-ibb01


    2. Navigate to Support directory on Compute node 1 as shown below

    [root@dm01db01 ~]# cd /opt/oracle.SupportTools/

    3. Oracle has provided a script *setup_ssh_eq.sh* to configure SSH equivalence across Exadata components. Execute the script as shown below. Here we are setting the SSH equivalence for root user

    [root@dm01db01 oracle.SupportTools]# ./setup_ssh_eq.sh ~/all_group root welcome1
    /root/.ssh/id_dsa already exists.
    Overwrite (y/n)?
    /root/.ssh/id_rsa already exists.
    Overwrite (y/n)?
    spawn dcli -c dm01db01 -l root -k
    dm01db01: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db02 -l root -k
    dm01db02: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db03 -l root -k
    dm01db03: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db04 -l root -k
    dm01db04: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db05 -l root -k
    dm01db05: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db06 -l root -k
    dm01db06: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db07 -l root -k
    dm01db07: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01db08 -l root -k
    dm01db08: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel01 -l root -k
    dm01cel01: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel02 -l root -k
    dm01cel02: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel03 -l root -k
    dm01cel03: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel04 -l root -k
    dm01cel04: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel05 -l root -k
    dm01cel05: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel06 -l root -k
    dm01cel06: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01cel07 -l root -k
    dm01cel07: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01sw-iba01 -l root -k
    dm01sw-iba01: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””
    spawn dcli -c dm01sw-ibb01 -l root -k
    dm01sw-ibb01: ssh key already exists
    expect: spawn id exp4 not open
        while executing
    “expect “*?assword:*””

    4. Verify SSH equivalence is working fine

    [root@dm01db08 ~]# dcli -g ~/all_group -l root ‘uptime’
    dm01db01: 09:16:41 up 21 days, 15:47,  1 user,  load average: 1.80, 3.02, 3.35
    dm01db02: 09:16:41 up 21 days, 15:38,  0 users,  load average: 2.93, 2.44, 2.37
    dm01db03: 09:16:41 up 21 days, 15:19,  0 users,  load average: 2.16, 2.27, 2.77
    dm01db04: 09:16:41 up 21 days, 15:12,  0 users,  load average: 4.07, 4.33, 4.14
    dm01db05: 09:16:41 up 21 days, 15:09,  0 users,  load average: 2.45, 2.82, 2.75
    dm01db06: 09:16:41 up 21 days, 15:06,  0 users,  load average: 1.70, 2.04, 2.60
    dm01db07: 09:16:41 up 21 days, 15:02,  0 users,  load average: 6.39, 4.46, 4.20
    dm01db08: 09:16:41 up 21 days, 14:59,  1 user,  load average: 1.66, 1.81, 1.97
    dm01cel01: 09:16:41 up 203 days, 19:00,  0 users,  load average: 1.40, 1.97, 2.21
    dm01cel02: 09:16:41 up 203 days, 18:59,  0 users,  load average: 1.52, 2.08, 2.38
    dm01cel03: 09:16:41 up 203 days, 18:59,  0 users,  load average: 1.00, 1.71, 2.02
    dm01cel04: 09:16:41 up 203 days, 18:59,  0 users,  load average: 1.08, 1.59, 1.92
    dm01cel05: 09:16:41 up 203 days, 18:59,  0 users,  load average: 1.24, 1.53, 1.82
    dm01cel06: 09:16:41 up 203 days, 18:59,  0 users,  load average: 1.09, 1.60, 1.96
    dm01cel07: 09:16:41 up 203 days, 19:00,  0 users,  load average: 1.01, 1.37, 1.60
    dm01sw-iba01: 09:16:42 up 539 days,  6:21,  0 users,  load average: 0.79, 0.99, 1.07
    dm01sw-ibb01: 14:49:54 up 539 days,  9:43,  0 users,  load average: 1.26, 1.44, 1.41

    [root@dm01db08 ~]# dcli -g dbs_group -l root ‘imageinfo | grep “Image version”‘
    dm01db01: Image version: 12.1.2.3.6.170713
    dm01db02: Image version: 12.1.2.3.6.170713
    dm01db03: Image version: 12.1.2.3.6.170713
    dm01db04: Image version: 12.1.2.3.6.170713
    dm01db05: Image version: 12.1.2.3.6.170713
    dm01db06: Image version: 12.1.2.3.6.170713
    dm01db07: Image version: 12.1.2.3.6.170713
    dm01db08: Image version: 12.1.2.3.6.170713



    [root@dm01db08 ~]# dcli -g cell_group -l root ‘imageinfo | grep “Active image version”‘
    dm01cel01: Active image version: 12.1.2.3.6.170713
    dm01cel02: Active image version: 12.1.2.3.6.170713
    dm01cel03: Active image version: 12.1.2.3.6.170713
    dm01cel04: Active image version: 12.1.2.3.6.170713
    dm01cel05: Active image version: 12.1.2.3.6.170713
    dm01cel06: Active image version: 12.1.2.3.6.170713
    dm01cel07: Active image version: 12.1.2.3.6.170713

    [root@dm01db08 ~]# ssh dm01sw-iba01 version
    SUN DCS 36p version: 2.1.8-1
    Build time: Sep 18 2015 10:26:47
    SP board info:
    Manufacturing Date: 2015.05.13
    Serial Number: “NCDKO0980”
    Hardware Revision: 0x0200
    Firmware Revision: 0x0000
    BIOS version: SUN0R100
    BIOS date: 06/22/2010

    Conclusion

    In this article we have learned how to configure SSH equivalence on Exadata Database Machine. Using the setup_ssh_eq.sh script is very easy setup SSH equivalence.
  • Create a Local Yum Repository Using an ISO Image on Exadata Database Machine

    You want to install some packages on the Exadata Compute nodes running Oracle Enterprise Linux and you don’t have internet access. In those cases you can create a local YUM repository using DVD Image. You simply download the DVD Image on the Desktop/Laptop where you have the internet access, copy it to the server and mount it.


    In this article we will demonstrate how create a Local YUM Repository using ISO Image on Exadata Database Machines.


    Prerequisites

    1. System with Internet
    2. Sufficient space on the server for Oracle Linux DVD ISO



    Steps to create a Local YUM Repository using ISO Image on Exadata Database Machines


    Step 1: Download Oracle Linux DVD Image from the Oracle Software Delivery Cloud at http://edelivery.oracle.com/linux


    Here I am downloading:
    V860937-01.iso Oracle Linux 6 Update 9 for x86 64 bit, 3.8 GB


    Step 2: Copy the DVD image to the server to a staging directory using Winscp


    Create a staging directory on the server


    [root@dm01db01 ~]# mkdir -p /u01/app/oracle/software/ISO


    Use Winscp to copy the ISO Image to the server


    [root@dm01db01 ~]# ls -l /u01/app/oracle/software/ISO
    total 3953672
    -rw-r–r– 1 root root 4048551936 Mar 20 04:18 V860937-01.iso


    Step 3:  Create a mount point, for example /mnt/OEL6.9, and mount the DVD image on it. 


    [root@dm01db01 ~]# mkdir -p /mnt/OEL6.9


    [root@dm01db01 ~]# ls -l /mnt/OEL6.9
    total 0


    [root@dm01db01 ~]# mount -o loop,ro /u01/app/oracle/software/ISO/V860937-01.iso /mnt/OEL6.9


    [root@dm01db01 ~]# df -h /mnt/OEL6.9
    Filesystem            Size  Used Avail Use% Mounted on
    /u01/app/oracle/software/ISO/V860937-01.iso
                          3.8G  3.8G     0 100% /mnt/OEL6.9


    [root@dm01db01 ~]# cd /mnt/OEL6.9


    [root@dm01db01 OEL6.9]# ls -l
    total 1686
    drwxr-xr-x 3 root root   2048 Mar 24  2017 EFI
    -rw-r–r– 1 root root   8529 Mar 24  2017 EULA
    -rw-r–r– 1 root root   8529 Mar 24  2017 eula.en_US
    -rw-r–r– 1 root root   3334 Mar 24  2017 eula.py
    -rw-r–r– 1 root root  18390 Mar 24  2017 GPL
    drwxr-xr-x 3 root root   2048 Mar 24  2017 HighAvailability
    drwxr-xr-x 3 root root   2048 Mar 24  2017 images
    drwxr-xr-x 2 root root   2048 Mar 24  2017 isolinux
    drwxr-xr-x 3 root root   2048 Mar 24  2017 LoadBalancer
    -rw-r–r– 1 root root     98 Mar 24  2017 media.repo
    drwxr-xr-x 2 root root 716800 Mar 24  2017 Packages
    -rw-r–r– 1 root root   7193 Mar 24  2017 README-en
    -rw-r–r– 1 root root   6016 Mar 24  2017 README-en.html
    -rw-r–r– 1 root root  81004 Mar 24  2017 RELEASE-NOTES-en
    -rw-r–r– 1 root root 227548 Mar 24  2017 RELEASE-NOTES-en.html
    -rw-r–r– 1 root root  81004 Mar 24  2017 RELEASE-NOTES-x86_64-en
    -rw-r–r– 1 root root 227548 Mar 24  2017 RELEASE-NOTES-x86_64-en.html
    -rw-r–r– 1 root root  81004 Mar 24  2017 RELEASE-NOTES-x86-en
    -rw-r–r– 1 root root 227548 Mar 24  2017 RELEASE-NOTES-x86-en.html
    lrwxrwxrwx 1 root root     15 Mar 24  2017 repodata -> Server/repodata
    drwxr-xr-x 3 root root   2048 Mar 24  2017 ResilientStorage
    -rw-r–r– 1 root root   1011 Mar 24  2017 RPM-GPG-KEY
    -rw-r–r– 1 root root   1011 Mar 24  2017 RPM-GPG-KEY-oracle
    drwxr-xr-x 3 root root   2048 Mar 24  2017 ScalableFileSystem
    drwxr-xr-x 4 root root   2048 Mar 24  2017 Server
    -rw-r–r– 1 root root    108 Mar 24  2017 supportinfo
    -r–r–r– 1 root root   6517 Mar 24  2017 TRANS.TBL
    drwxr-xr-x 3 root root   2048 Mar 24  2017 UEK4


    Step 4:  Add an entry to the /etc/fstab file, this will to auto mount the DVD image after a reboot. 


    /u01/app/oracle/software/ISO/V860937-01.iso /mnt/OEL6.9 iso9660 loop,ro 0 0


    [root@dm01db01 ~]# vi /etc/fstab


    [root@dm01db01 ~]# cat /etc/fstab
    LABEL=DBSYS             /                       ext4    defaults        1 1
    LABEL=BOOT              /boot                   ext4    defaults,nodev        1 1
    LABEL=DBORA             /u01                    ext4    defaults,nodev  1 1
    tmpfs                   /dev/shm                tmpfs   defaults,size=258341m 0
    devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
    sysfs                   /sys                    sysfs   defaults        0 0
    proc                    /proc                   proc    defaults        0 0
    LABEL=SWAP              swap                    swap    defaults        0 0
    /u01/app/oracle/software/ISO/V860937-01.iso /mnt/OEL6.9 iso9660 loop,ro 0 0


    Step 5:  Navigate to /etc/yum.repos.d directory, you can edit the existing repository files public-yum-ol6.repo or create a new repo file such as ULN-base.repo, and disable all entries by setting enabled=0. 


    [root@dm01db01 ~]# cd /etc/yum.repos.d


    [root@dm01db01 yum.repos.d]# ls -l
    total 20
    -rw-r—– 1 root root  291 Mar 31 22:43 Exadata-computenode.repo
    -r–r—– 1 root root  896 Jan 26 06:19 Exadata-computenode.repo.sample
    -rw-r–r– 1 root root 7299 Mar 20 05:57 public-yum-ol6.repo


    Here I am going to create the OL69.repo repository file and add the entries 


    [root@dm01db01 yum.repos.d]# vi OL69.repo


    [root@dm01db01 yum.repos.d]# cat OL69.repo
    [OL69]
    name=Oracle Linux 6.9 x86_64
    baseurl=file:///mnt/OEL6.9
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY
    gpgcheck=1
    enabled=1


    Step 7:  Perform YUM Cache cleanup as below


    [root@dm01db01 yum.repos.d]# yum clean all
    Cleaning repos: OL69
    Cleaning up Everything


    Step 8:  Perform a test to ensure you can access yum repository


    [root@dm01db01 yum.repos.d]# yum repolist
    OL69                          | 3.7 kB      00:00 …
    OL69/primary_db                | 3.1 MB      00:00 …
    repo id                        repo name    status    
    OL69                          Oracle Linux 6.9 x86_64 3,860
    repolist: 3,860




    Conclusion


    In this article we have learned how to create local YUM repository using DVD ISO Image on Exadata Database Machine. Configuring a local YUM repository comes handy when you want to install packages on the server and you don’t have internet access from the server.

  • Mount External USB Drive On Exadata Compute Node

    You have files on an External USB drive that you want to connect to Exadata Compute node to copy them over to the server file system. This can be done for several reasons such as Database Migration.




    In this article I will demonstrate step by step how to mount an Exadata USB drive to Exadata Compute node.


    Steps to mount External USB on Exadata Compute node


    • Connect the External USB drive to Exadata Compute node. This can be done easily by Data Center Engineer who has access to Data Center and Exadata Rack.
    • Once the USB is connected, Verify you can see it on the Exadata Compute node by running the following command.

    [root@dm01db01 ~]# multipath -l
    33e41384658514e52 dm-5 Seagate,Expansion Desk
    size=3.6T features=’0′ hwhandler=’0′ wp=rw
    `-+- policy=’round-robin 0′ prio=0 status=active
      `- 7:0:0:0 sdb 8:16 active undef unknown


    You can also use “fdisk -l” command to list the connected USB.


    [root@dm01db01 ~]# fsdisk -l
    ….
                             Device Boot      Start         End      Blocks   Id  System
    /dev/mapper/33e41384658514e52p1               1      267350  2147483647+  ee  GPT
    Partition 1 does not start on physical sector boundary.


    [root@dm01db01 ~]# ls -l /dev/mapper/
    total 0
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 33e41384658514e52 -> ../dm-5
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 33e41384658514e52p1 -> ../dm-6
    crw-rw—- 1 root root 10, 236 Apr 22 14:23 control
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 VGExaDb-LVDbOra1 -> ../dm-3
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 VGExaDb-LVDbSwap1 -> ../dm-2
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 VGExaDb-LVDbSys1 -> ../dm-0
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 VGExaDb-LVDbSys2 -> ../dm-1
    lrwxrwxrwx 1 root root       7 Apr 24 18:53 VGExaDb-LVDoNotRemoveOrUse -> ../dm-4


    • Create a mount point

    [root@dm01db01 mnt]# mkdir -p /mnt/dbmigration


    • Verify the file system type for mounting purpose. Here the it is ext4

    [root@dm01db01 mnt]# mount -l
    /dev/mapper/VGExaDb-LVDbSys1 on / type ext4 (rw) [DBSYS]
    proc on /proc type proc (rw)
    sysfs on /sys type sysfs (rw)
    devpts on /dev/pts type devpts (rw,gid=5,mode=620)
    tmpfs on /dev/shm type tmpfs (rw,size=775461m)
    /dev/sda1 on /boot type ext4 (rw,nodev) [BOOT]
    /dev/mapper/VGExaDb-LVDbOra1 on /u01 type ext4 (rw,nodev) [DBORA]
    none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
    sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
    nfsd on /proc/fs/nfsd type nfsd (rw)


    • Mount the External USB on the local mount point created.

    [root@dm01db01 ~]# mount -t ext4 /dev/mapper/33e41384658514e52p1 /mnt/dbmigration


    • Verify the UBS is mounted successfully

    [root@dm01db01 ~]# df -h /mnt/dbmigration
    Filesystem            Size  Used Avail Use% Mounted on
    /dev/mapper/33e41384658514e52p1
                          2.0T   99G  1.8T   6% /mnt/dbmigration


    • Change directory permissions and ownership to Oracle

    [root@dm01db01 ~]# chown oracle:oinstall -R /mnt/dbmigration


    [root@dm01db01 ~]# chmod 775 -R /mnt/dbmigration


    • Verify the permissions and ownership

    [root@dm01db01 ~]# ls -ld /mnt/dbmigration
    drwxrwxr-x 4 oracle oinstall 4096 Apr 25 09:49 /mnt/dbmigration


    • Verify that that you can access and list the contents from USB.

    [root@dm01db01 ~]# cd /mnt/dbmigration


    [root@dm01db01 dbmigration]# ls -ltr
    total 103004260
    -rw-r—– 1 500 500 6786600960 Apr 25 11:25 expdp_full.dmp
    -rw-r—– 1 500 500 7231434752 Apr 25 11:25 expdp_schema.dmp
    -rw-r–r– 1 500 500     129609 Apr 25 11:30 expdp_schemas.log




    Conclusion


    In this article we have learned how to mount an External USB drive on Exadata Compute node.

  • Exadata Pocket Reference

    Here is the Link to the Exadata Pocket Reference. Click on the Link to Download the file.

    Exadata Pocket Reference

  • Exadata – Configure Compute Node and Storage Cell SMTP Email Notification

    On Exadata Database Machine you can configure the following Compute Node and Storage Cell attributes to setup the database server and Storage cells to send notifications about alerts.
    • smtpServer
    • smtpFrom
    • smtpFromAddr
    • smtpToAddr
    • snmpSubscriber
    • notificationMethod
    • notificationPolicy

    In this article we will demonstrate how to setup the database server and Storage cells to send notifications about alerts

    Compute Nodes:




    Configure Compute nodes SMTP email notification for alerts. This can be accomplished using dbmcli alter dbserver command




    # Compute node 1

    DBMCLI>alter dbserver smtpFrom=’Exadata – dm01db01′



    DBMCLI>alter dbserver smtpFromAddr=’dbmadmin@dm01db01.netsoftmate.com’
    DBMCLI>alter dbserver smtpToAddr=’oradba@netsoftmate.com’
    DBMCLI>alter dbserver smtpServer=’smtp.server’
    DBMCLI>alter dbserver snmpSubscriber=((host=192.168.10.1,port=162,community=public,type=ASR))
    DBMCLI>alter dbserver notificationPolicy=’critical,warning,clear’
    DBMCLI>alter dbserver notificationMethod=’mail,snmp’
    DBMCLI>alter dbserver validate mail

    Or you can use the following command

    DBMCLI>alter dbserver smtpFrom=’Exadata – dm01db01′, smtpFromAddr=’dbmadmin@dm01db01.netsoftmate.com’, smtpToAddr=’oradba@netsoftmate.com’, smtpServer=’smtp.server’, snmpSubscriber=’host=192.168.10.1,port=162,community=public,type=ASR’, notificationPolicy=’critical,warning,clear’, notificationMethod=’mail,snmp’

    DBMCLI>alter dbserver validate mail




    *** Repeat the above step for all the Compute nodes in the cluster.

    # verify

    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | grep smtpFrom”



    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | grep smtpFromAddr”
    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | grep smtpToAddr”
    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | grep smtpServer”
    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | grep notificationMethod”

    or use the following command




    # dcli -g ~/dbs_group -l root “dbmcli -e ‘list dbserver detail’ | egrep ‘(smtpFrom|smtpFromAddr|smtpToAddr|smtpServer|notificationMethod)’”







    Storage Cells:



    Configure Compute nodes SMTP email notification for alerts. This can be accomplished using cellcli alter cell command



    # Storage Cell 01

    CELLCLI>alter cell smtpFrom=’Exadata – dm01cel01′



    CELLCLI>alter cell smtpFromAddr=’celladmin@dm01cel01.netsoftmate.com’
    CELLCLI>alter cell smtpToAddr=’oradba@netsoftmate.com’
    CELLCLI>alter cell smtpServer=’smtp.server’
    CELLCLI>alter cell snmpSubscriber=((host=192.168.10.1,port=162,community=public,type=ASR))
    CELLCLI>alter dbserver notificationPolicy=’critical,warning,clear’
    CELLCLI>alter cell notificationMethod=’mail,snmp’
    CELLCLI>alter cell validate mail

    or you can also use the following command




    CELLCLI>alter cell smtpFrom=’Exadata – dm01cel01′, smtpFromAddr=’celladmin@dm01cel01.netsoftmate.com’, smtpToAddr=’oradba@netsoftmate.com’, smtpServer=’smtp.server’, notificationMethod=’mail,snmp’

    CELLCLI>alter cell validate mail



    # Verify



    # dcli -g ~/cell_group -l root “dbmcli -e ‘list cell detail’ | grep smtpFrom”



    # dcli -g ~/cell_group -l root “dbmcli -e ‘list cell detail’ | grep smtpFromAddr”
    # dcli -g ~/cell_group -l root “dbmcli -e ‘list cell detail’ | grep smtpToAddr”
    # dcli -g ~/cell_group -l root “dbmcli -e ‘list cell detail’ | grep smtpServer”
    # dcli -g ~/cell_group -l root “dbmcli -e ‘list cell detail’ | grep notificationMethod”

    or you can use the following command




    # dcli -g ~/cell_group -l root “cellcli -e ‘list cell detail’ | egrep ‘(smtpFrom|smtpFromAddr|smtpToAddr|smtpServer|notificationMethod)’”





    *** Repeat the above step for all the Storage Cells in the cluster.





    Conclusion





    In this article we have learned how to Configure Compute nodes and Storage Cell SMTP email notification for alerts.