Forum Stats

  • 3,759,037 Users
  • 2,251,494 Discussions
  • 7,870,477 Comments

Discussions

Rman post backup issue

User_AWGXQ
User_AWGXQ Member Posts: 4 Green Ribbon

RMAN succeeds with the backups, but the below datafiles are in active status. when I ran the end backup manually, the status gets updated. but again after the next backup, it is back to the same status. Also, the pdb$seed's datafile change# is updated with 0.

Please assist on this. 

db - 19.8 running on Win

--

SQL> select * from v$backup;


   FILE# STATUS        CHANGE# TIME     CON_ID

---------- ------------------ ---------- --------- ----------

     1 ACTIVE       2.1936E+10 14-MAR-21     1

     2 NOT ACTIVE         0          2

     3 ACTIVE       2.1936E+10 14-MAR-21     1

     4 NOT ACTIVE         0          2

     5 ACTIVE       2.1936E+10 14-MAR-21     1

     6 NOT ACTIVE         0          2

     7 NOT ACTIVE     2.1929E+10 14-MAR-21     1

    12 NOT ACTIVE     2.1929E+10 14-MAR-21     3

    13 NOT ACTIVE     2.1929E+10 14-MAR-21     3

    14 NOT ACTIVE     2.1929E+10 14-MAR-21     3

>>

Thanks

Answers

  • EdStevens
    EdStevens Member Posts: 28,467 Gold Crown

    Well, it would certainly help if we knew exactly what rman commands you were using . . . .

  • User_AWGXQ
    User_AWGXQ Member Posts: 4 Green Ribbon

    Please find the commands,

    CONFIGURE CONTROLFILE AUTOBACKUP ON; 

    CONFIGURE BACKUP OPTIMIZATION OFF; 

    CONFIGURE DEVICE TYPE DISK BACKUP TYPE TO COMPRESSED BACKUPSET;  

    CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'G:\Rman\PROD_2021-03-14\%F';

    CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'G:\Rman\PROD_2021-03-14\%U' MAXPIECESIZE = 10G;

    CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 2 DAYS;

    CROSSCHECK BACKUPSET;

    CROSSCHECK ARCHIVELOG ALL;

    BACKUP DATABASE PLUS ARCHIVELOG;

    DELETE NOPROMPT OBSOLETE RECOVERY WINDOW OF 2 DAYS DEVICE TYPE DISK;


  • User_AWGXQ
    User_AWGXQ Member Posts: 4 Green Ribbon

    SQL> alter database end backup;

    alter database end backup

    *

    ERROR at line 1:

    ORA-01260: warning: END BACKUP succeeded but some files found not to be in

    backup mode



    SQL> select * from v$backup;


       FILE# STATUS        CHANGE# TIME     CON_ID

    ---------- ------------------ ---------- --------- ----------

         1 NOT ACTIVE     2.1936E+10 14-MAR-21     1

         2 NOT ACTIVE         0          2

         3 NOT ACTIVE     2.1936E+10 14-MAR-21     1

         4 NOT ACTIVE         0          2

         5 NOT ACTIVE     2.1936E+10 14-MAR-21     1

         6 NOT ACTIVE         0          2

         7 NOT ACTIVE     2.1929E+10 14-MAR-21     1

        12 NOT ACTIVE     2.1929E+10 14-MAR-21     3

        13 NOT ACTIVE     2.1929E+10 14-MAR-21     3

        14 NOT ACTIVE     2.1929E+10 14-MAR-21     3

        15 NOT ACTIVE     2.1929E+10 14-MAR-21     3

    >>

    47 rows selected.


    SQL> alter database begin backup;


    Database altered.


    SQL> alter database end backup;


    Database altered.


    SQL> select * from v$backup;


       FILE# STATUS        CHANGE# TIME     CON_ID

    ---------- ------------------ ---------- --------- ----------

         1 NOT ACTIVE     2.1958E+10 17-MAR-21     1

         2 NOT ACTIVE         0          2

         3 NOT ACTIVE     2.1958E+10 17-MAR-21     1

         4 NOT ACTIVE         0          2

         5 NOT ACTIVE     2.1958E+10 17-MAR-21     1

         6 NOT ACTIVE         0          2

         7 NOT ACTIVE     2.1958E+10 17-MAR-21     1

        12 NOT ACTIVE     2.1958E+10 17-MAR-21     3

        13 NOT ACTIVE     2.1958E+10 17-MAR-21     3

        14 NOT ACTIVE     2.1958E+10 17-MAR-21     3

        15 NOT ACTIVE     2.1958E+10 17-MAR-21     3

    >>

    47 rows selected.


    SQL>


  • EdStevens
    EdStevens Member Posts: 28,467 Gold Crown

    So why the ALTER DATABASE END BACKUP? That is for when you are performing a 'user managed backup'. The rman script you showed is not performaing a user managed backup. No should it. I haven't used a user managed backup since rman came on the scene.

    subhajitsahakolkataindia
  • User_AWGXQ
    User_AWGXQ Member Posts: 4 Green Ribbon

    I am using the given RMAN commands to perform the backups and not using user-managed backup. Since some datafiles are in Active status in v$backup after the RMAN backup, the database does not allow to perform a shutdown. Hense need to run user manage backup steps to perform a smooth shutdown.

  • subhajitsahakolkataindia
    subhajitsahakolkataindia Member Posts: 1 Green Ribbon

    Hi Guys,

    Just to add, we should not forget one thing that v$backup view is useful only for user managed online tablespace backups. This is because neither RMAN backups nor offline tablespace backups require the datafiles of a tablespace to be in backup mode. So that means, somewhere or the other in your environment some other backups are configured except the rman backup. This is the only plausible explanation that I can come up with.

    Thanks,

    Subhajit