Backup - restore IDS 7.31 on Solaris and Win NT
Posted in 2009
Kurt asked whether logical logs backed up with 'ontape -c' can be rolled forward after restoring an offline file copy of an IDS 7.31 instance. John Miller and Art Kagel explained that a cold copy taken with the server shut down can't be combined with logs; instead you must use external backup/restore ('onmode -c block', copy chunks/config, 'onmode -c unblock'), available since 7.3, then restore with onbar -r -e -p followed by onbar -r -l. Kurt's test stalled in fast recovery and onbar failed (missing ixbar/sm_versions/libbsa, ontape logs not usable by ON-Bar, so ISM setup appears needed). No resolution is recorded in the thread.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Topics: Backup & Restore, Logging & Checkpoints, Platform-Specific Issues, Versions, Editions & End-of-Life
Hello,
We take offline backups, this means we shut down the instance and then take a
copy of the datafiles and config-files.
Logical logs are backued up via 'ontape -c'.
Is it possible, using the backed up logical logs, to rollforward the database
after a restore?
Thanks in advance for your answers!
Shutting down the database server will not allow you to
blend the logs with your offline copy. If you modify your
step to follow the external back and restore this will work.
1. do an onmode -c block
2. Copy all datafiles and config-files
3. do an onmode -c unblock
During that time you can NOT take the IDS instance offline.
Now if you want to do a restore and utilize the logical logs it will
work just fine. See the manual for more details.
If you system is down and you can not recover you can try
calling tech support and they probably can help you utilize
your offline backup and logs
John F. Miller III
STSM, Support Architect
miller3@us.ibm.com
503-578-5645
IBM Informix Dynamic Server (IDS)
ids-bounces@iiug.org wrote on 09/15/2009 05:30:34 AM:
> [image removed]
>
> Backup - restore IDS 7.31 on Solaris and Win NT [17005]
>
> KURT VAN GOMPEL
>
> to:
>
> ids
>
> 09/15/2009 05:31 AM
>
> Sent by:
>
> ids-bounces@iiug.org
>
> Please respond to ids
>
> Hello,
>
> We take offline backups, this means we shut down the instance and then
take a
> copy of the datafiles and config-files.
> Logical logs are backued up via 'ontape -c'.
>
> Is it possible, using the backed up logical logs, to rollforward
thedatabase
> after a restore?
>
> Thanks in advance for your answers!
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
Kurt,
Version and platform information are always helpful to get an answer that is
useful to you. For example, if you are running IDS v 11.50 you can roll
forward the logical logs after a physical restore of an external (or
offline) backup, yes. If you are using an earlier release then, no.
BTW, you should be aware that except for the oldest versions of IDS (version
info about what you have would help again) you can take an external backup
of the IDS instance without taking the engine offline at all! You just have
to execute a checkpoint and block the engine from modifying the disk image
while the disks are being copied. This is accomplished with the 'onmode -c
block' command. Once the disks have been copied, or if you are using
mirrored disks, once the mirrors have been broken so you can make the backup
copy from the emancipated mirrors, you release the instance to resume
writing to disk with 'onmode -c unblock'. If you are using the separated
mirror copies for the backup process, then you would reestablish the mirrors
once the copy operation has completed and let them catch up.
While it seems that you are aware of this, it can't hurt to note that
offline and external backups are not required, though they are often faster
than online backups, IDS is capable of taking archives while online as well.
Art
Art S. Kagel
Oninit (www.oninit.com)
IIUG Board of Directors (art@iiug.org)
Disclaimer: Please keep in mind that my own opinions are my own opinions and
do not reflect on my employer, Oninit, the IIUG, nor any other organization
with which I am associated either explicitly or implicitly. 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 Tue, Sep 15, 2009 at 8:30 AM, KURT VAN GOMPEL <
kvangompel@caami-hziv.fgov.be> wrote:
> Hello,
>
> We take offline backups, this means we shut down the instance and then take
> a
> copy of the datafiles and config-files.
> Logical logs are backued up via 'ontape -c'.
>
> Is it possible, using the backed up logical logs, to rollforward the
> database
> after a restore?
>
> Thanks in advance for your answers!
>
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
--0015174a047a23c6e304739f77ae
Hello John, Thanks for your response! As I mentioned in the subject, we are still using IDS 7.31! Is the explanation you gave also valid for this version? I looked in some manuals but didn't find anything about an external backup. What command(s) do I use to rollforward the databases using the logical logs after restoring the datafiles (backed up after blocking the instance)? Thanks for your help.
Hi Art, First of all, thans for your answer! As I mentioned in the subject, we still use IDS 7.31 (UD1 on Solaris8, TC6 on Windows NT). So, if I understand well, in our case we can't use the logical logs to rollforward the databases.
External Backup and Restore was introduced in 7.3 I would just look at the latest documentation for it online http://publib.boulder.ibm.com/infocenter/idshelp/v115/index.jsp search on "external backup" It is the only way to integrate and external backup of the datafiles (dbspace & chunks) with a recovery of the logical logs. John F. Miller III STSM, Support Architect miller3@us.ibm.com 503-578-5645 IBM Informix Dynamic Server (IDS) ids-bounces@iiug.org wrote on 09/15/2009 08:55:58 AM: > [image removed] > > Re: Backup - restore IDS 7.31 on Solaris and Win N [17013] > > KURT VAN GOMPEL > > to: > > ids > > 09/15/2009 08:56 AM > > Sent by: > > ids-bounces@iiug.org > > Please respond to ids > > Hi Art, > > First of all, thans for your answer! > As I mentioned in the subject, we still use IDS 7.31 (UD1 on Solaris8, TC6 on > Windows NT). > So, if I understand well, in our case we can't use the logical logs to > rollforward the databases. > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. >
Hi John,
I did some tests today but didn't get very far.
No problem to block the instance, copy the files and then unblock.
...
15:42:01 Logical Log 2338 Complete.
15:43:15 Checkpoint Completed: duration was 0 seconds.
15:43:15 Dynamic Server blocked.
15:48:16 Checkpoint Completed: duration was 0 seconds.
16:00:01 Logical Log 2339 Complete.
16:00:27 Logical Log 2339 - Backup Started
16:03:17 Checkpoint Completed: duration was 0 seconds.
16:05:40 Dynamic Server unblocked.
...
I stopped the instance, and copied the files back to their original directory.
Then I ran the command 'onbar -r -e -p' to do the external restore.
After a few seconds, I see in the logfile that the external restore is
finished but the server remains in 'Fast Recovery (CHKPT REQ)'.
...
16:10:58 Informix Dynamic Server Stopped.
16:26:20 Segment locked: addr=0xc000000, size=457441280
16:26:20 Requested shared memory segment size rounded from 150000KB to 150016KB
16:26:20 Could not disable priority aging: errno = 0
Wed Sep 16 16:26:20 2009
16:26:20 Could not disable priority aging: errno = 0
16:26:24 DR: DRAUTO is 0 (Off)
16:26:26 Informix Dynamic Server Version 7.31.TC6 Software Serial Number
AAC#A893072
16:26:28 Informix Dynamic Server Initialized -- Shared Memory Initialized.
16:26:28 Dataskip is now OFF for all dbspaces
16:26:28 Recovery Mode
16:26:34 External restore started.
16:26:34 External restore Completed.
...
It stays in Fast recovery untill I bring it to multiuser manually with 'onmode
-m' from another terminal. Then recovery continues and the server comes online.
...
16:50:40 Physical Recovery Started.
16:50:41 Physical Recovery Complete: 0 Pages Restored.
16:50:41 Logical Recovery Started.
16:50:41 Checkpoint Completed: duration was 1 seconds.
16:50:46 Logical Recovery Complete.
0 Committed, 0 Rolled Back, 0 Open, 0 Bad Locks
16:50:46 Bringing system to On-Line Mode with no Logical Restore.
16:50:47 On-Line Mode
...
The ONBAR logfile shows the following lines:
2009-09-16 16:26:19 495 99 C:\\\\INFORMIX\\\\bin\\\\onbar_d -r -e -p
2009-09-16 16:26:34 495 99 Open or close failed on file
'C:\\\\INFORMIX/etc/ixbar.197', errno = 2
2009-09-16 16:26:39 495 99 ON-Bar is waiting for the database server to exit
fast recovery mode.
2009-09-16 16:50:45 495 99 ON-Bar is waiting for the database server to exit
fast recovery mode.
2009-09-16 16:51:00 495 99 External Restore failed: 100
I don't know if this is the normal way to perform the restore.
I don't know either how I can rollforward the logical logs.
In the manual they say to run a 'onbar -r -l' after the physical restore but
that generates errors in the ONBAR logfile:
2009-09-16 17:43:50 182 480 C:\\\\INFORMIX\\\\bin\\\\onbar_d -r -l
2009-09-16 17:43:58 182 480 ERROR: Unable to open file
C:\\\\ISM\\\\2.20\\\\bin\\\\libbsa.dll
2009-09-16 17:43:58 182 480 ERROR: Unable to open file
C:\\\\INFORMIX/etc/sm_versions
No such file or directory
Till now, I backup the logical logs using 'ontape'. Are these compatible with
onbar?
Should I backup them with 'onbar'? This should mean I have to set up ISM!!