Diffrences between ontape -l and ontape -l -C
Posted in 2015
Carlos (IDS 11.7 on RHEL 6.2) asked how 'ontape -l' differs from 'ontape -l -C', after failing to repeatedly roll logical logs forward onto a standby machine ('no DBspaces or BLOBspaces to recover', chunks shown inconsistent/offline). Answers: plain -l restores logs then quiesces, while -l -C is for Continuous Log Restore, leaving the server in recovery mode so more logs can be applied later. Art Kagel outlined the proper sequence: physical-only restore (ontape -p), then repeated 'ontape -l -C' as logs arrive, issuing no onmode commands; chunks stay marked inconsistent until you finalize with 'ontape -l -X' to bring the server online. Carlos confirmed this worked.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Topics: Backup & Restore
Good morning
I would like to know the differences between the next commands:
ontape -l
ontape -l -C
Thanks
Carlos
OS and IDS Versions ??
Manual (v11.7 and greater) seems to indicate this option will automatically
begin restoring logs from the currently loaded log tape without prompting
for mounting. Might be good, might be bad. Personnally I like fine control
over restores and to authorise any action so I would not tend to use it I
don't think.
Keith
On 13 April 2015 at 09:11, CARLOS CAMBRONERO <ccmarquina@gmail.com> wrote:
> Good morning
>
> I would like to know the differences between the next commands:
>
> ontape -l
> ontape -l -C>
> Thanks
>
> Carlos
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--001a113feeb69630350513986154
Please see:
http://www-01.ibm.com/support/knowledgecenter/#!/SSGU8G_12.1.0/com.ibm.bar.doc/i
ds_bar_153.htm
In the above article, both commands are used to setup Continuous Log Restore
using ontape.
"ontape -l" will restore logical logs and quiesce the server once all logical
logs included in the backup being restored had been replayed.
"ontape -l -C" will restore logical logs and leave the instance in fast
recovery mode allowing you to restore more logical logs as they become
available.
Sent from my iPhone
> On 13 Apr 2015, at 20:15, Keith Simmons <smiley73@gmail.com> wrote:
>
> OS and IDS Versions ??
> Manual (v11.7 and greater) seems to indicate this option will automatically
> begin restoring logs from the currently loaded log tape without prompting
> for mounting. Might be good, might be bad. Personnally I like fine control
> over restores and to authorise any action so I would not tend to use it I
> don't think.
>
> Keith
>
>> On 13 April 2015 at 09:11, CARLOS CAMBRONERO <ccmarquina@gmail.com> wrote:
>>
>> Good morning
>>
>> I would like to know the differences between the next commands:
>>
>> ontape -l
>> ontape -l -C>>
>> Thanks
>>
>> Carlos
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
> --001a113feeb69630350513986154
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
*******************************************************************************
>> Forum Note: Use "Reply" to post a response in the discussion forum.
>
> --001a113feeb69630350513986154
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
> --001a113feeb69630350513986154
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
My OS is RedHat 6.2 and IDS 11.7.
I have some problems to restore the logical logs in the machine backup, If I
use the command "ontape -l -C" the logical log are restored, but the chuncks
are with inconsistent status. If I use the command "ontape -l", I can't repeat
this command several times, because I have the next message:
Logical restore failed - There are no DBspaces or BLOBspaces to recover.
Check the status by using onstat -d.
My main machine is configured with "ontape -c", then every logical log file
generated is copied in the backup machine to restore 'm it.
I'm not able to find the commands neccesary to restore the logical logs in the
backup machine.
Could you help me?
Thanks
Carlos
Carlos:
ontape -l -C is used to setup Continuous Log Restore. This is a form ofreplication and is not normally used for restoring a server from archives
and bringing it up-to-date. At this point, to bring your server online,
just run "onmode -m" and wait for the server to be in full "on-line" mode.
Normally to restore a server and roll forward logical logs you would just
perform a normal restore (ontape -r) and it will restore the logs prompting
for any tapes or files that it needs. If you performed a physical only
restore (ontape -p) that will also leave the server in the state you
describe. To bring the server online from that point without rolling logs
forward just run the "onmode -m" command and wait. To roll forward logical
logs first run "ontape -l" (without the -C) and restore the logs. Running
"onmode -m" when you have finished rolling logs forward will bring it
online.
Art
Art S. Kagel, President and Principal Consultant
ASK Database Management
www.askdbmgt.com
Blog: http://informix-myview.blogspot.com/
Disclaimer: Please keep in mind that my own opinions are my own opinions
and do not reflect on the IIUG, nor any other organization with which I am
associated either explicitly, implicitly, or by inference. Neither do
those opinions reflect those of other individuals affiliated with any
entity with which I am affiliated nor those of the entities themselves.
On Mon, Apr 13, 2015 at 6:48 AM, CARLOS CAMBRONERO <ccmarquina@gmail.com>
wrote:
> My OS is RedHat 6.2 and IDS 11.7.
>
> I have some problems to restore the logical logs in the machine backup, If
> I
> use the command "ontape -l -C" the logical log are restored, but the
> chuncks
> are with inconsistent status. If I use the command "ontape -l", I can't
> repeat
> this command several times, because I have the next message:
>
> Logical restore failed - There are no DBspaces or BLOBspaces to recover.
> Check the status by using onstat -d.
>
> My main machine is configured with "ontape -c", then every logical log file
> generated is copied in the backup machine to restore 'm it.
>
> I'm not able to find the commands neccesary to restore the logical logs in
> the
> backup machine.
>
> Could you help me?
>
> Thanks
>
> Carlos
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--90e6ba1efdac3c8102051398f999
Thanks Art:
But after to execute onmode -m, I can't access DB:
Chunks
address chunk/dbs offset size free bpages flags pathname
46f571d0 1 1 0 78848 70451 PI-B-D
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/rootdbs
46f57930 2 2 0 15360 459 PI-B-D
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/physdbs
46f57b30 3 3 0 13312 971 PI-B-D
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/logdbs
46f57d30 4 4 0 397312 392141 PI-B-D
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/datadbs
47067450 5 5 0 16384 -1 -1 PISB-D
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/sbspace
47067650 6 6 0 99328 99250 PI-B--
/usr/local/pr/informix_1170/ol_informix1170/dbspaces/tempdbs
6 active, 32766 maximum
The chunks are in offline.
Thanks
Carlos
That will happen if you shutdown the engine and restart it before bringing
it fully online. If that's where you are, the only fix I know is to
shutdown do a full restore and log roll forward followed by bringing the
engine fully online (onmode -m) before shutting it down.
Art
Art S. Kagel, President and Principal Consultant
ASK Database Management
www.askdbmgt.com
Blog: http://informix-myview.blogspot.com/
Disclaimer: Please keep in mind that my own opinions are my own opinions
and do not reflect on the IIUG, nor any other organization with which I am
associated either explicitly, implicitly, or by inference. Neither do
those opinions reflect those of other individuals affiliated with any
entity with which I am affiliated nor those of the entities themselves.
On Mon, Apr 13, 2015 at 9:08 AM, CARLOS CAMBRONERO <ccmarquina@gmail.com>
wrote:
> Thanks Art:
>
> But after to execute onmode -m, I can't access DB:
>
> Chunks
> address chunk/dbs offset size free bpages flags pathname
> 46f571d0 1 1 0 78848 70451 PI-B-D
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/rootdbs
> 46f57930 2 2 0 15360 459 PI-B-D
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/physdbs
> 46f57b30 3 3 0 13312 971 PI-B-D
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/logdbs
> 46f57d30 4 4 0 397312 392141 PI-B-D
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/datadbs
> 47067450 5 5 0 16384 -1 -1 PISB-D
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/sbspace
> 47067650 6 6 0 99328 99250 PI-B--
> /usr/local/pr/informix_1170/ol_informix1170/dbspaces/tempdbs
> 6 active, 32766 maximum
>
> The chunks are in offline.
>
> Thanks
>
> Carlos
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--20cf302920d6b0963f05139af5a9
Hi Art
I think that is an issue. I'm not able to find workaround to do incremental
restore in backup machine with the command ontape. I have a script to simetry
the logical logs file in the backup machine and to restore them, every that a
new logical log file is generated in the main machine.
Thanks
Carlos
What you are describing is what Informix calls Continuous Log Restore. You
do an initial physical restore using ontape -p or onbar -r -p and respond
"N" to prompts about level 1 archives and backing up logical logs before
starting the restore. Leave the server in recovery mode (ie no onmode
commands at all!) Then you use ontape -l -C or onbar -r -l -C to roll
forward any logical logs, again, leaving the server in recovery mode.
Periodically, either one at a time or in batches, you use ontape -l -C or
onbar -r -l -C to roll forward logical log files archived from the primaryserver as they become available. Only if you need to have the backup
server take over for a failed primary do you complete the process by
running ontape -l -X or onbar -r -l -X to finalize the log restore process
and put the server into on-line mode.
All chunks will remain marked as "I"nconsistent until the log restore is
finalized and the server brought online.
Art
Art S. Kagel, President and Principal Consultant
ASK Database Management
www.askdbmgt.com
Blog: http://informix-myview.blogspot.com/
Disclaimer: Please keep in mind that my own opinions are my own opinions
and do not reflect on the IIUG, nor any other organization with which I am
associated either explicitly, implicitly, or by inference. Neither do
those opinions reflect those of other individuals affiliated with any
entity with which I am affiliated nor those of the entities themselves.
On Mon, Apr 13, 2015 at 10:27 AM, CARLOS CAMBRONERO <ccmarquina@gmail.com>
wrote:
> Hi Art
>
> I think that is an issue. I'm not able to find workaround to do incremental
> restore in backup machine with the command ontape. I have a script to
> simetry
> the logical logs file in the backup machine and to restore them, every
> that a
> new logical log file is generated in the main machine.
>
> Thanks
>
> Carlos
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--001a1140f3f05fdb1a05139c6b98
Hi Art Your solution works fine. Thanks a lot for your help. Regards Carlos
Related threads
- IDS 10 table-level restore
- Informix Development Webinar December 11, 2007
- ontape -p/r with changed ROOTPATH
- Migrate from HP PA-RISC to HP ITANIUM by ontape