RMAN - how to alter date formats in logfile
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 6 of 6

Thread: RMAN - how to alter date formats in logfile

  1. #1
    Join Date
    Oct 2002
    Posts
    807

    RMAN - 1) altering date formats in logfile 2) backing up init.ora, password file

    I've got 2 questions :

    1) Is there a way to change date formats on the RMAN logfile? I'm not talking about the file formats specified in the script..but the date that appears in the logfile itself. Altering my session's nls_date format doesn't do it.

    For eg, when I initiate a backup, my logfile looks like the below. Notice the highlighted line. It merely specifies a date. There is no timestamp..I wish to include a timestamp in the log. Any suggestions?

    2) How does one backup init.ora (not spfile) and password files in RMAN?

    THanks, Anand

    RMAN> run { execute script dwdev_incr0; }

    executing script: dwdev_incr0

    released channel: ORA_DISK_1
    allocated channel: t1
    channel t1: sid=16 devtype=SBT_TAPE
    channel t1: Tivoli Data Protection for Oracle: version 5.2.0.0

    allocated channel: t2
    channel t2: sid=17 devtype=SBT_TAPE
    channel t2: Tivoli Data Protection for Oracle: version 5.2.0.0

    Starting backup at 21-APR-04

    channel t1: starting incremental level 0 datafile backupset
    channel t1: specifying datafile(s) in backupset
    including current controlfile in backupset
    input datafile fno=00022 name=/u03/oradata/DWDEV/retail_dat1_01.dbf
    input datafile fno=00017 name=/u06/oradata/DWDEV/pos_dat2_01.dbf
    .....
    .....
    Last edited by Axr2; 04-21-2004 at 03:27 PM.

  2. #2
    Join Date
    Aug 2002
    Location
    Atlanta
    Posts
    1,187

    Re: RMAN - 1) altering date formats in logfile 2) backing up init.ora, password file

    Originally posted by Axr2
    I've got 2 questions :

    1) Is there a way to change date formats on the RMAN logfile? I'm not talking about the file formats specified in the script..but the date that appears in the logfile itself. Altering my session's nls_date format doesn't do it.
    I don't think you can change that


    2) How does one backup init.ora (not spfile) and password files in RMAN?
    RMAN can't back uo the init file, why are you using it anyway unless you're on 8i
    I'm stmontgo and I approve of this message

  3. #3
    Join Date
    Aug 2002
    Location
    Atlanta
    Posts
    1,187

    Re: Re: RMAN - 1) altering date formats in logfile 2) backing up init.ora, password file

    Originally posted by stmontgo
    I don't think you can change that



    RMAN can't back up the init file, why are you using it anyway unless you're on 8i
    I'm stmontgo and I approve of this message

  4. #4
    Join Date
    Oct 2002
    Posts
    807
    > RMAN can't back up the init file, why are you using it anyway unless you're on 8i

    I've already tried asking my client to use an SPFILE.

    I work for an ASP (hosting company). In this particular client's case, my role is merely restricted to backing up their database and stops at that. The client continues to use an init.ora. It's not easy "convincing" their DBA's to use to an spfile..esp since it needs some downtime to bounce the database. Every one from VP down needs to give a "blessing" for a quick bounce. I'm just gonna back it up outside.

    Coming back to the timestamp issue :
    So how do you exactly track when the backup exactly started and finished? Just embed sql into the script and write to a logfile?

    Thanks, Anand
    Last edited by Axr2; 04-22-2004 at 07:35 PM.

  5. #5
    Join Date
    Aug 2002
    Location
    Atlanta
    Posts
    1,187
    Wel you could look at the time stamp of the rman log, I just checked our logs end with

    Finished backup at 08-APR-04

    Recovery Manager complete.

    so yeah the time is not there. I just know that my backup starts at 9pm and that the logile says 9:18 so I'm assuming it took 18 minutes.

    The spfile works like a champ (nasty bug if you're using RAC though)
    and then you can backup/restore the whole shooting match with RMAN.

    Why not create the spfile, rename the init file to .old
    and then on the next reboot you'll be using the spfile?

    Steve
    I'm stmontgo and I approve of this message

  6. #6
    Join Date
    Oct 2002
    Posts
    807
    stmontgo, FYI -
    Setting the NLS_DATE_FORMAT does change the RMAN timestamps that I was looking for. I had messed up my profile options..nevermind.

    oracle@dwdev01[/export/home/oracle/rman/DWDEV] export NLS_DATE_FORMAT='DD-mon-YYYY HH24:MI:SS'

    RMAN> run { execute script dwdev_periodic_arch_bkup; }

    executing script: dwdev_periodic_arch_bkup

    released channel: ORA_DISK_1
    allocated channel: t1
    channel t1: sid=18 devtype=SBT_TAPE
    channel t1: Tivoli Data Protection for Oracle: version 5.2.0.0

    Starting backup at 26-apr-2004 16:54:24

    current log archived
    channel t1: starting archive log backupset
    channel t1: specifying archive log(s) in backup set
    input archive log thread=1 sequence=57725 recid=599 stamp=524505111

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width