With Oracle and EMC you set the database into hot backup mode, perform
the split mirror, then take the database out of hot backup mode.
Something tells me it will be onmode -c block or onmode -c unblock as the
equivalent. I tried this on my own test box, then went to Google to see
if I was on the right track. You can test this on a developer instance to
see how it works. I don't have a SAN handy to test on so you'll have to
script on your own. Whatever SAN you use, the terminology will be something
like 'split mirror' or BCV.
onmode -c block
onstat
IBM Informix Dynamic Server Version 11.50.FC2DE -- On-Line -- Up 2 days 05:51:53 -- 39728 Kbytes
Blocked:ARCHIVE
.
. do the split mirror here
.
onstat
onmode -c unblock
IBM Informix Dynamic Server Version 11.50.FC2DE -- On-Line -- Up 2 days 05:52:52 -- 39728 Kbytes
See also:
===========
"Look into the command: onmode -c block
You run this, and it does a checkpoint and blocks any more activity to the disks. You then split off the bcv mirror.
Because you did a checkpoint, the split copy will be consistient at the time of the checkpoint.
To re-enable disk activity, do:
onmode -c unblock
I believe there is a white paper on Informix's website about this."
===========
You can search Google for 'Informix BCV' or 'Informix split mirror'
and get more info.
-ID-
Have a read of the backup and restore guide here
http://publib.boulder.ibm.com/infocenter/idshelp/v115/topic/com.ibm.bar.
doc/bar.htm.
It is for version 11.50, but the guts are the same as version 9.
Also - which version of 9 is it? 9.0 was very different to 9.2 and then
there were major advances on 9.40
-----Original Message-----
From: Vince Tai [mailto:vinc...@icon-info.com.hk]
Sent: Tuesday, 25 November 2008 4:26 p.m.
To: Jarrod Teale
Cc: Vince Tai
Subject: Re: informix and SAN snapshot
Dear Jarrod,
Thanks for your reply. However, when should I use the command "onbar"?
Thanks.
Regards, Vince
"Jarrod Teale" <Jarrod...@fonterra.com> wrote in message
news:<mailman.384.12275813...@iiug.org>...
You can block the database using "onmode -c block" - it causes the
database to enter a checkpoint and wait for you to issue the "onmode -c
unblock" command to let the database proceed. This will block all
transactions while you are doing the snapshot though - no caching etc
and users will get error messages when they try to do anything.
Jarrod Teale
Fonterra NZ.
________________________________
From: informix-l...@iiug.org
[mailto:informix-l...@iiug.org] On Behalf Of vt
Sent: Tuesday, 25 November 2008 3:20 p.m.
To: inform...@iiug.org
Subject: informix and SAN snapshot
Hi all Informix experts,
i would like to put the Informix DB v9.x on SAN and take snapshots daily
so that in case there is data corruption, I can rollback to previous
version. However, I found Informix is a bit different from Oracle and
Sybase as they have backup modes but Informix doesn't have. (Correct me
if I'm wrong)
I did do some researches on the Internet and found a utility called
onbar. Can I use this command to temporarily freeze the DB before I take
a snapshot on the SAN so that the snapshot taken will have no integrity
issue? If so, during the snapshoting, where will the new transactions
go? Will the new transactions be temporarily stored on somewhere else?
Thanks a lot in advance.
Regards, vt
----------
DISCLAIMER:
This email contains confidential information and may be legally privileged. If you are not the intended recipient or have received this email in error, please notify the sender immediately and destroy this email.
You may not use, disclose or copy this email or its attachments in any way.
Any opinions expressed in this email are those of the author and are not necessarily those of the Fonterra Co-operative Group.
http://www.fonterra.com/
Sorry I didn't see your post... we must've both posted close to the same
time. I'm curious if you use Informix MVCC if this is the case, that is,
are the users still blocked? I'd think if MVCC is being used that it would be
like Oracle, but I'm not sure. Looks like worse case you have to create
a maintenance window and get users off the system for the split. However,
it will only be lengthy the first time, at least with EMC. Subsequent
splits should be on the order of a few seconds.
At any rate looks like you've confirmed what I was thinking is the right
thing to do, how long it takes to complete is another matter.
-ID-
-----Original Message-----
From: informix-l...@iiug.org
[mailto:informix-l...@iiug.org] On Behalf Of InDeep
Sent: Tuesday, 25 November 2008 4:58 p.m.
To: inform...@iiug.org
Subject: Re: informix and SAN snapshot
-ID-
_______________________________________________
Informix-list mailing list
Inform...@iiug.org
http://www.iiug.org/mailman/listinfo/informix-list
I'm actually trying to put Informix v9.3r5 on EMC SAN.
I've already contacted EMC and they said there's no such snapshot agent for
Informix. However, EMC backup software called Networker does have a backup
agent for Informix. The agent is an API which interacts w/ the "Onbar"
utility to backup the DB to tape even though the DB is still online. It
seems to me even though the backup is in progress, the DB can still accept
new transactions. I'm wondering if I can apply this approach to SAN backup /
snapshot. But heard from Derby, it seems that there's no way to accept new
transactions when backup is in progress.
Regards,
"InDeep" <ind...@indeep.com> wrote in message
news:492b752e$0$18357$6c36...@news.usenetserver.com...
You want to use the term 'split mirror' or BCV.
Follow the pseudo code I gave you. It's that simple.
Once the database is blocked, start your BCV.
Once the BCV is completed, unblock your database.
It's not as difficult as it seems, however, EMC has made a lot of
money off of their complexity.
To Informix's credit it is much simpler than Oracle.
-ID-
Hi,
Change the process from Indeep slightly.
Here's how we do it:
Shutdown DB on backup server
Do resync from PRODUCTION to BACKUP
When all copies are in sync
do
onmode -c block
check all copies are done
split mirrors off
onmode -c block
done
This way you dont have to wait for the copiues to be done (which can
take upto 8 hours).users can still work on prod. You only block the
instance on PROD for the duration of the split, 15 seconds the users
experince lag.
Cheers
I'm running a standalone Informix on SUN V880.
But I have another spare SUN V880, not in use yet. Do you mean I should
setup another Informix (as backup host) on the spare machine, and mirror the
DB on production host to the backup host?
Regards, vt
<14inf...@gmail.com> wrote in message
news:d2b17e9f-e195-42f5...@t3g2000yqa.googlegroups.com...
No, just do what InDeep and Jarold said. You don't need to call EMC, and
you don't need to use onbar (at this point). I don't think 14informix added
anything new (and didn't really understand his bit about "Shutdown DB on
backup server" (I assume as soon as the split is complete he mounts the
split database disks on a backup server, which immediately destroys his
capability of rolling forward subsequent logs)) but he did helpfully clarify
the point that the onmode -c block/unblock operation need only be used
during the *split*, not the sync as well - 2-3 seconds for me on a 1TB
database on Symmetrix.
Where you would need onbar is if you need to doa restore then log
roll-forward: you combine onbar (probably ontape can be used too) with
Informix's "external restore" functionality to roll forward any backed-up.
post-split logical logs.
VT, are you familiar enough with the EMC BCV process?
Like I said before Informix makes it easier than Oracle. In Oracle I have to run SQL
scripts and do a lot of return-code management to manage the database, in Informix it's
easier because of the onmode command on the command-line. I think in Oracle they actually
have to set up their instances a certain way to do hot backups (I'm not an Oracle DBA) .
Good luck with it.
-ID-
If you are doing a Symmetrix sync ( not rsync ) you are pushing bits
from prod to the other servers' disks, thusly you will need to shut down
your target db or there will be corruption. Once the two are in-sync,
it's time to split them. Once they are split they are each on their own
again, the target can be brought back up.
The oiriginal poster wants the disk copy as a backup. not to use for any
othr purpose. Therefore, I don't understand this idea of "shutting down the
target server" and "bringing it back up". You just the leave the disk copy
intact, maybe refreshing it nightly, for years on end without ever pointing
a server at it *except* when you need to use it.
The minute you bring Informix up on it the disk copy is destroyed as a
potential source for a point-in-time restore using logical logs.
Everyone here has great information but onbar is the most difficult
backup method to setup. Snap, too, takes some effort. Since you are
new to all this, I recommend that you start with something easy. Just
put "TAPEDEV /path_name/backup_filename" in the $ONCONFIG file and
then run "ontape -s -L 0". This method is slow but reliable.
-L.S.
Just a bit more confusion...
I'm not sure about the purpose of this... But you need to really think about
it. Everything said before makes sense, and it will work. But what is your
purpose? Let's see...
- You'll have a database snapshot taken at a precise time. OnBar and ontape
(much simpler) will also do that and ontape won't cost you anything.
- What are you protecting against? What will happen if you take your snapshot
at midnight and you hit major problems at 11H AM? Will you just go back to
midnight image? Will that satisfy your business needs?
- What if you drop a table by mistake, or simply do an update/delete with the
wrong conditions? Will you simply revert the database for midnight snapshot?
Will that satisfy you business needs?
- Assuming your SAN storage makes a copy to you local facilities, what will
happen to your database and your backup image? And to your business....?
Unless these questions are being considered, I'd advise you start reading the
IBM Informix Backup and Restore Guide. Is has a nice introduction to backup
issues and considerations from a "policy" point of view. Then it drives you
through all the technical stuff. It isn't too specific about SAN technologies,
but it should mention the "external backup and restore" (onmode -c block/onmode
-c unblock)
Regards
--
Fernando Nunes
Portugal
http://informix-technology.blogspot.com
My email works... but I don't check it frequently...
> Like I said before Informix makes it easier than Oracle. In Oracle I have
> to run SQL
> scripts and do a lot of return-code management to manage the database, in
> Informix it's
> easier because of the onmode command on the command-line. I think in
> Oracle they actually
> have to set up their instances a certain way to do hot backups (I'm not an
> Oracle DBA) .
It's not *that* difficult on Oracle. We use the technique for Oracle as
well as Informix. Steps are:
ALTER DATABASE BEGIN BACKUP;
ALTER SYSTEM SUSPEND;
/sbin/sync
/sbin/sync
<do EMC split>
ALTER SYSTEM RESUME;
ALTER DATABASE END BACKUP;
and it works well.
Good points Fernando. BCVs are not appropriate for all situations, but
the larger your database becomes, the more problematic it is to manage
backups.
A lot of sites are going to reconsider BCVs, expensive apps, and expensive
storage in favor of more agile solutions. I think Informix is in a good
position to meet a lot of those needs, but again, as I always say, apps
drive databases, not the other way around. Until we start to see more apps
on Informix, businesses will continue to use expensive storage, expensive
databases, and expensive backups.
-ID-