cancel
Showing results for 
Search instead for 
Did you mean: 

how to extend disk image expiration?

manatee
Level 6

NBU 7.6.0.3

i have a restore running from a disk image. it is not yet done and i'm afraid the time for the disk image to expire is quite near.

how do i extend the expiry on this disk image so as not to affect the restore?

1 ACCEPTED SOLUTION

Accepted Solutions

sdo
Moderator
Moderator
Partner    VIP    Certified

Ok - that image "ruh1erpdb2_1456090629" has two copies:

Number of Copies:  2

...copy 1 is on:  disk storage id:  @aaaan     expiration:  Tue 23 Feb 2016 12:37:09 AM

...copy 2 is on:  tape:  ABP210                      expiration:  Mon 29 Feb 2016 12:37:09 AM

.

So, we need to extend the life of copy 1, using:

...do this command first:

bpexpdate -h

...then view the date format shown by the help then do this (but change the date format if you need to):

bpexpdate -copy 1 -backupid ruh1erpdb2_1456090629 -recalculate -d mm/dd/yyyy hh:mm:ss

...and you will be prompted to confirm whether to do this?

N.B:  My strong advice here:    Get a colleague of yours to check the output from bpexpdate -h, and verify that you are using the correct date format for real... two pairs of eyes are better than one!  :)

View solution in original post

9 REPLIES 9

manatee
Level 6

ok i  found the command.

bpexpdate -recalculate -d 02/23/2016 05:00:00 -backup id <xxx>

but question now is, can i use the above command on the disk image currently being used by the restore?

manatee
Level 6

this is the bpimage list of the disk image currently being restored:

Client:            ruh1erpdb2
Backup ID:         ruh1erpdb2_1456090629
Policy:            Daily_ruh1erpdb2
Policy Type:       Oracle (4)
Proxy Client:      (none specified)
Creator:           oraprod
Name1:             (none specified)
Sched Label:       Default-Application-Backup
Schedule Type:     UBAK (2)
Retention Level:   1 day (4)
Backup Time:       Mon 22 Feb 2016 12:37:09 AM AS (1456090629)
Elapsed Time:      13907 second(s)
Expiration Time:   Tue 23 Feb 2016 12:37:09 AM AS (1456177029)
Maximum Expiration Time:   Mon 29 Feb 2016 12:37:09 AM AS (1456695429)
Compressed:        no
Client Encrypted:  no
Kilobytes:         1127208736
Number of Files:   1
Number of Copies:  2
Number of Fragments:   25
Histogram:         0 0 0 0 0 0 0 0 0 0
DB Compressed:     no
Files File Name:   Daily_ruh1erpdb2_1456090629_UBAK.f
Previous Backup Files File Name:   (none specified)
Parent Backup Image File Name:   (none specified)
SW Version:        (none specified)
Options:           0x0
MPX:               0
TIR Info:          0
TIR Expiration:    Thu 01 Jan 1970 03:00:00 AM AS (0)
Keyword:           PROD
Ext Security Info: no
File Restore Raw:  no
Image Dump Level:  0
File System Only:  no
Object Descriptor: (none specified)
Previous BI Time:  Thu 01 Jan 1970 03:00:00 AM AS (0)
BI Full Time:      Thu 01 Jan 1970 03:00:00 AM AS (0)
Request Pid:       0
Backup Status:     0
Stream Number:     0
Backup Copy:       Standard (0)
Files File size:     656
PFI type:     0
IMAGE_ATTRIBUTE:     0
Primary Copy:      1
Image Type:        0  (Regular)
Job ID:            265062

Num Resumes:       1
Resume Expiration: Thu 01 Jan 1970 03:00:00 AM AS (0)
Data Classification:    Gold
Data_Classification_ID: 9F5AC974364911E2857CAC40773EEAED
Storage Lifecycle Policy:    Oracle_Daily_Policy
Storage Lifecycle Policy Version:    1
STL_Completed:      3
Remote Expiration Time: Thu 01 Jan 1970 03:00:00 AM AS (0)
Origin Master Server:  (none specified)
Origin Master GUID:    (none specified)
Snap Time:      Thu 01 Jan 1970 03:00:00 AM AS (0)
IR Enabled:      no
Client Character Set:     12
Image On Hold:     0
Indexing Status:   0
Copy number:       1
 Fragment:         1
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 Expiration Time:  Tue 23 Feb 2016 12:37:09 AM AS (1456177029)
 MPX:              0
 retention_lvl:    1 day (4)
 Try to Keep Time:  Tue 23 Feb 2016 12:37:09 AM AS (1456177029)
 Copy Creation Time:  Mon 22 Feb 2016 04:28:56 AM AS (1456104536)
 Data Format:      Tar
 checkpoint:       0
 resume num:       0
 Key tag:          *NULL*
 STL tag:          *NULL*
 Copy on hold:     0
Copy number:       1
 Fragment:         2
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0

 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         3
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         4
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1

 Fragment:         5
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         6
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         7
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1

 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         8
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         9
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         10
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0

 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         11
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         12
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1

 Fragment:         13
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         14
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         15
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)

 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         16
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         17
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         18
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)

 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         19
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         20
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0

Copy number:       1
 Fragment:         21
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         22
 Kilobytes:        51200000
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)
 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       1
 Fragment:         23
 Kilobytes:        808736
 Remainder:        0
 Media Type:       Disk (0)
 Density:          qscsi (0)
 File Num:         0
 ID:               @aaaan
 Host:             ovmmanager
 Block Size:       1048576
 Offset:           0
 Media Date:       Thu 01 Jan 1970 03:00:00 AM AS (0)

 Dev Written On:   -1
 Flags:            0x4
 Media Descriptor:        1;PureDisk;ovmmanager;NBU-PureDisk-1;PureDiskVolume;0
 checkpoint:       0
 resume num:       0
 Copy on hold:     0
Copy number:       2
 Fragment:         1
 Kilobytes:        431014912
 Remainder:        0
 Media Type:       Media Manager (2)
 Density:          hcart2 (14)
 File Num:         272
 ID:               ABP210
 Host:             ovmmanager
 Block Size:       262144
 Offset:           16961229
 Media Date:       Sat 20 Feb 2016 04:55:07 PM AS (1455976507)
 Dev Written On:   0
 Flags:            0x0
 Media Descriptor:        ?
 Expiration Time:  Mon 29 Feb 2016 12:37:09 AM AS (1456695429)
 MPX:              0
 retention_lvl:    1 week (0)
 Try to Keep Time:  Mon 29 Feb 2016 12:37:09 AM AS (1456695429)
 Copy Creation Time:  Mon 22 Feb 2016 09:40:23 AM AS (1456123223)
 Data Format:      Tar
 checkpoint:       0
 resume num:       1
 Key tag:          *NULL*
 STL tag:          *NULL*
 Copy on hold:     0
Copy number:       2
 Fragment:         2
 Kilobytes:        696193824
 Remainder:        0
 Media Type:       Media Manager (2)
 Density:          hcart2 (14)
 File Num:         1
 ID:               ABP187
 Host:             ovmmanager
 Block Size:       262144
 Offset:           2
 Media Date:       Mon 22 Feb 2016 05:34:57 AM AS (1456108497)
 Dev Written On:   0
 Flags:            0x0
 Media Descriptor:        ?
 checkpoint:       0

 resume num:       1
 Copy on hold:     0

 

manatee
Level 6

it's copy 1. so the command is,

bpexpdate -cn 1 -recalculate <date time> -backupid <image-name>

 

but can it be used on an image that is currently being used for restore?

sdo
Moderator
Moderator
Partner    VIP    Certified

I don't know for 100% sure whether bpexpdate can be used on a copy which is being read, but it won't hurt to try... as long as you get the date format correct !

manatee
Level 6

well it accepted. btw, there is no "-cn" parameter so i used "-copy" instead. we're using the default date format (makes it less confusing) that comes with the OS.

so far, it is still restoring from that image.

thanks for your timely help!

sdo
Moderator
Moderator
Partner    VIP    Certified

Ok - that image "ruh1erpdb2_1456090629" has two copies:

Number of Copies:  2

...copy 1 is on:  disk storage id:  @aaaan     expiration:  Tue 23 Feb 2016 12:37:09 AM

...copy 2 is on:  tape:  ABP210                      expiration:  Mon 29 Feb 2016 12:37:09 AM

.

So, we need to extend the life of copy 1, using:

...do this command first:

bpexpdate -h

...then view the date format shown by the help then do this (but change the date format if you need to):

bpexpdate -copy 1 -backupid ruh1erpdb2_1456090629 -recalculate -d mm/dd/yyyy hh:mm:ss

...and you will be prompted to confirm whether to do this?

N.B:  My strong advice here:    Get a colleague of yours to check the output from bpexpdate -h, and verify that you are using the correct date format for real... two pairs of eyes are better than one!  :)

sdo
Moderator
Moderator
Partner    VIP    Certified

Look in the activity monitor restore job details tab for a single string which looks like:

<client-name><underscore><10-digits>

e.g.:

myclient.my.com_1234567890

...this is known as the "image name"...

...then do:

bpimagelist -L -backupid <image-name>

...and look for the copy number which is on the disk storage unit, and then do (where 'N' is the copy number on disk):

bpexpdate -copy N -recalculate <date time> -backupid <image-name>

.

If you need help, post the output of the bpimagelist above, and one of us will give you the exact command to use for bpexpdate.

 

sdo
Moderator
Moderator
Partner    VIP    Certified

Cool - and if you don't mind I will amend my posts above (if I can) to use "-copy" instead of "-cn" (sorry about that :o) in case anyone else needs to use this post as reference.

sdo
Moderator
Moderator
Partner    VIP    Certified

The funny thing is... if... either the MM or the DD part (of the date used for bpexpdate) are greater than 12... then bpexpdate will complain if you get the date format wrong.  Which is handy.

But of course if both the DD and MM parts of the date are both 12 or less - then one is not warned (obviously) if one gets it wrong.  Not so good.

.

Here's my tip for a method of exactly determining the date format for bpexpdate in ones own environment - irrespective of what the help text says:

.

When doing manual one-off bpexpdate on any (all copies of) image, or even like just now with one specific copy, then what one can do first - BEFORE modifying any real backup images - is...

(both)       bpexpdate -backupid -gibberish.blah_1234567890 -recalculate -d 12/31/2037 00:00:00

...then...

...Unix:     echo $?

...Windows:  echo %errorlevel%

...and if you get error 227, then one has the date format correct (but of course the image was not found ;).

...and if you get error 20, then one has the date format wrong.