ontape -r -t STDIO Level 1
Posted in 2008
Question: how to make a non-interactive `ontape -r -t STDIO` restore continue on to a level 1 after the level 0. Suggestions were to use expect, but the simple answer from IBM's Martin Fuerderer was just to feed both archives in sequence on stdin, e.g. `cat arc_0 arc_1 | ontape -r -t STDIO` (zcat of both compressed files worked too). The poster first thought the level 1 was ignored, then confirmed it worked: the online log showed the checkpoint advancing to the level 1's log position, leaving the instance at the level 1 archive point with no logical log restore needed.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Probably a dump question but ...
Is there any way to script or otherwise persuade an ontape -r -t STDIO so
that, when it finsishes restoring a level 0, it can then be made to process
a level 1?
thx
Neil
Neil Truby wrote:
> Probably a dump question but ...
>
> Is there any way to script or otherwise persuade an ontape -r -t STDIO so
> that, when it finsishes restoring a level 0, it can then be made to process
> a level 1?
>
> thx
> Neil
>
>
http://expect.nist.gov/
--
Clive
Neil Truby wrote: > Probably a dump question but ... You mean a shit one? :o) -- Bye now, Obnoxio "There were a myriad of problems which conspired to corrupt your reason and rob you of your common sense. Fear got the best of you, and in your panic you turned to the Labour Party. They promised you order, they promised you peace, and all they demanded in return was your silent, obedient consent."
Hi,
just provide the level-1 archive right after the level-0 archive as
input.
Assuming your level-0 archive is in file "arc_0" and your
level-1 archive is in file "arc_1". Then you do:
cat arc_0 arc_1 | ontape -r -t STDIO
That should work.
Probably a dumb answer ...
[ Sorry, but I couldn't resist, also couldn't resist to change p to b ;) ]
Regards,
Martin
--
Martin Fuerderer
IBM Informix Development Munich, Germany
Information Management
IBM Deutschland Entwicklung GmbH
Chairman of the Supervisory Board: Martin Jetter
Board of Management: Herbert Kircher
Corporate Seat: Boeblingen, Germany
Reg.-Gericht: Amtsgericht Stuttgart, HRB 243294
informix-list-bounces@iiug.org wrote on 19.03.2008 01:59:43:
> Probably a dump question but ...
>
> Is there any way to script or otherwise persuade an ontape -r -t STDIO
so
> that, when it finsishes restoring a level 0, it can then be made to
process
> a level 1?
>
> thx
> Neil
>
>
> _______________________________________________
> Informix-list mailing list
> Informix-list@iiug.org
> http://www.iiug.org/mailman/listinfo/informix-list
Martin Fuerderer" <MARTINFU@de.ibm.com> wrote in message
news:mailman.724.1205923641.20610.informix-list@iiug.org...
> Hi,
>
> just provide the level-1 archive right after the level-0 archive as
> input.
> Assuming your level-0 archive is in file "arc_0" and your
> level-1 archive is in file "arc_1". Then you do:
>
> cat arc_0 arc_1 | ontape -r -t STDIO
>
> That should work.
I did:
zcat IDSDAT.19172.18032008.gz 1.dmp_level1_3.gz | ontape -r -t STDIO
(where zcat IDSDAT.19172.18032008.gz is the compressed Level 0 and
1.dmp_level1_3.gz the compressed Level 1)
and the Level 1 was just ignored :-(
--
Neil Truby t:01932 724027
Director m:07798 811708
Ardenta Limited e:neil.truby@ardenta.com
"Neil Truby" <neil.truby@ardenta.com> wrote in message
news:64dhh2F2bec8sU1@mid.individual.net...
> Martin Fuerderer" <MARTINFU@de.ibm.com> wrote in message
> news:mailman.724.1205923641.20610.informix-list@iiug.org...
>> Hi,
>>
>> just provide the level-1 archive right after the level-0 archive as
>> input.
>> Assuming your level-0 archive is in file "arc_0" and your
>> level-1 archive is in file "arc_1". Then you do:
>>
>> cat arc_0 arc_1 | ontape -r -t STDIO
>>
>> That should work.
>
> I did:
>
> zcat IDSDAT.19172.18032008.gz 1.dmp_level1_3.gz | ontape -r -t STDIO
> (where zcat IDSDAT.19172.18032008.gz is the compressed Level 0 and
> 1.dmp_level1_3.gz the compressed Level 1)
>
> and the Level 1 was just ignored :-(
Sorry, I take it back. Seems like it did work. The current log at the time
of the Level 0 was 36148, and at the Level 1 was 36183. How does that work
then? Here's the online log for the restore:
23:11:10 Maximum server connections 0
23:12:08 Checkpoint Completed: duration was 0 seconds.
23:12:08 Checkpoint loguniq 36148, logpos 0x106a018, timestamp: 0xc5755c03
23:12:08 Maximum server connections 0
23:12:08 Physical Restore of rootdbs, physdbs, llogdbs, orbisdbs1
Completed.
23:12:08 Checkpoint Completed: duration was 0 seconds.
23:12:08 Checkpoint loguniq 36148, logpos 0x106a018, timestamp: 0xc78dcdc7
23:12:08 Maximum server connections 0
23:12:10 No logical log restore will be performed.
23:12:10 Preparing Physical Log for Fast Recovery ...
23:12:10 Clearing the physical and logical logs has started
23:15:33 Cleared 3968 MB of the physical and logical logs in 202 seconds
23:15:33 Physical Recovery Started at Page (2:34307).
23:15:33 Physical Recovery Complete: 0 Pages Examined, 0 Pages Restored.
23:15:33 Logical Recovery Started.
23:15:33 10 recovery worker threads will be started.
23:15:33 Checkpoint Completed: duration was 0 seconds.
23:15:33 Checkpoint loguniq 36183, logpos 0x3e78018, timestamp: 0xc78dcdf2
23:15:33 Maximum server connections 0
23:15:35 Logical Recovery has reached the transaction cleanup phase.
23:15:35 Logical Recovery Complete. 0 Committed, 0 Rolled Back, 0 Open, 0 Bad Locks
23:15:36 Bringing system to Quiescent Mode with no Logical Restore.
23:15:37 Quiescent Mode
Hi,
I'm not sure about the intention of your question.
The answer is that it works. I don't see a problem.
The level-1 archive contains all the changes since
the level-0 archive. So by restoring the level-1 archive
after restoring the level-0 archive, all these changes
will be "applied". Hence after restore of level-1 archive
the instance is in the state where it was at the archive
checkpoint of the level-1 archive (at archive time).
And that's where your system is after the restore:
> 23:15:33 Checkpoint loguniq 36183, logpos 0x3e78018, timestamp:0xc78dcdf2
And this is of course without restoring the logical logs.
But this is the main reason why level-1 and level-2
backups are done in the first place, because they
avoid having to restore all those log files inbetween.
I hope this answers your question.
Regards,
Martin
--
Martin Fuerderer
IBM Informix Development Munich, Germany
Information Management
IBM Deutschland Entwicklung GmbH
Chairman of the Supervisory Board: Martin Jetter
Board of Management: Herbert Kircher
Corporate Seat: Boeblingen, Germany
Reg.-Gericht: Amtsgericht Stuttgart, HRB 243294
informix-list-bounces@iiug.org wrote on 19.03.2008 23:21:51:
>
> --
> Neil Truby t:01932 724027
> Director m:07798 811708
> Ardenta Limited e:neil.truby@ardenta.com
>
> "Neil Truby" <neil.truby@ardenta.com> wrote in message
> news:64dhh2F2bec8sU1@mid.individual.net...
> > Martin Fuerderer" <MARTINFU@de.ibm.com> wrote in message
> > news:mailman.724.1205923641.20610.informix-list@iiug.org...
> >> Hi,
> >>
> >> just provide the level-1 archive right after the level-0 archive as
> >> input.
> >> Assuming your level-0 archive is in file "arc_0" and your
> >> level-1 archive is in file "arc_1". Then you do:
> >>
> >> cat arc_0 arc_1 | ontape -r -t STDIO
> >>
> >> That should work.
> >
> > I did:
> >
> > zcat IDSDAT.19172.18032008.gz 1.dmp_level1_3.gz | ontape -r -t STDIO
> > (where zcat IDSDAT.19172.18032008.gz is the compressed Level 0 and
> > 1.dmp_level1_3.gz the compressed Level 1)
> >
> > and the Level 1 was just ignored :-(
>
> Sorry, I take it back. Seems like it did work. The current log at the
time
> of the Level 0 was 36148, and at the Level 1 was 36183. How does that
work
> then? Here's the online log for the restore:
>
> 23:11:10 Maximum server connections 0
> 23:12:08 Checkpoint Completed: duration was 0 seconds.
> 23:12:08 Checkpoint loguniq 36148, logpos 0x106a018, timestamp:0xc5755c03
>
> 23:12:08 Maximum server connections 0
> 23:12:08 Physical Restore of rootdbs, physdbs, llogdbs, orbisdbs1
> Completed.
> 23:12:08 Checkpoint Completed: duration was 0 seconds.
> 23:12:08 Checkpoint loguniq 36148, logpos 0x106a018, timestamp:0xc78dcdc7
>
> 23:12:08 Maximum server connections 0
> 23:12:10 No logical log restore will be performed.
> 23:12:10 Preparing Physical Log for Fast Recovery ...
> 23:12:10 Clearing the physical and logical logs has started
> 23:15:33 Cleared 3968 MB of the physical and logical logs in 202seconds
> 23:15:33 Physical Recovery Started at Page (2:34307).
> 23:15:33 Physical Recovery Complete: 0 Pages Examined, 0 Pages
Restored.
> 23:15:33 Logical Recovery Started.
> 23:15:33 10 recovery worker threads will be started.
> 23:15:33 Checkpoint Completed: duration was 0 seconds.
> 23:15:33 Checkpoint loguniq 36183, logpos 0x3e78018, timestamp:0xc78dcdf2
>
> 23:15:33 Maximum server connections 0
> 23:15:35 Logical Recovery has reached the transaction cleanup phase.
> 23:15:35 Logical Recovery Complete.> 0 Committed, 0 Rolled Back, 0 Open, 0 Bad Locks
>
> 23:15:36 Bringing system to Quiescent Mode with no Logical Restore.
>
> 23:15:37 Quiescent Mode>
> _______________________________________________
> Informix-list mailing list
> Informix-list@iiug.org
> http://www.iiug.org/mailman/listinfo/informix-list