dbTalk Databases Forums  

ASA 9.0.2 database unload and reload

sybase.public.sqlanywhere.general sybase.public.sqlanywhere.general


Discuss ASA 9.0.2 database unload and reload in the sybase.public.sqlanywhere.general forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
MD
 
Posts: n/a

Default ASA 9.0.2 database unload and reload - 10-30-2007 , 07:46 PM







On one of our key ASA 9.0.2 databse ,we want to perform DBUnload and reload
operation.

The steps we outlined are as follows -

1) Make sure there are no connections / open transactions on the server
2) Unload the database
3) Create a new database using DBINIT
4) Defragment the drive
5) Load the database

I request your help in following -

1) In order to preserve current options set for the server and database and
apply to the newly created
database, is there any easy way to extract all settings of current
server/database ?
2) Which format of DBUnload you suggest, and, what are the benefits.
(ie. internal-internal or internal-external or external-internal or
external-external)
3) Are there any known issues or cautions that we should look for.

Thanks for your help and appreciate your response.



Reply With Quote
  #2  
Old   
Stephen Rice
 
Posts: n/a

Default Re: ASA 9.0.2 database unload and reload - 10-31-2007 , 05:45 AM






Did you look at dbunload -an which does 2,3 and 5 in one step and handles
your questions 1&2 for you. You can defrag the drive after building the
database which will ensure the .db file has the minimum number of fragments

As a more complete answer:

1) dbunload automatically preserves all options you have set in the
database. The only thing you need to manage are the dbinit parameters.
dbunload -an manages those for you as well.

2) whenever possible a server side (internal/internal) unload/reload is best
since it involves the "least amount of work". The others all work fine they
just involve more processing

3) No and yes. Be paranoid. Just because lots of people do this process
all of the time without incident does not mean that Murphy will not invade
your site. Take a backup before you start this process. Make sure you
validate a copy of the backup. Test your recovery plan.
--
/steve - if I had a Canadian nickel for every time I've heard "I don't have
a good backup"...
Stephen Rice
Sybase iAnywhere

"MD" <md0710 (AT) gmail (DOT) com> wrote

Quote:
On one of our key ASA 9.0.2 databse ,we want to perform DBUnload and
reload operation.

The steps we outlined are as follows -

1) Make sure there are no connections / open transactions on the server
2) Unload the database
3) Create a new database using DBINIT
4) Defragment the drive
5) Load the database

I request your help in following -

1) In order to preserve current options set for the server and database
and apply to the newly created
database, is there any easy way to extract all settings of current
server/database ?
2) Which format of DBUnload you suggest, and, what are the benefits.
(ie. internal-internal or internal-external or external-internal or
external-external)
3) Are there any known issues or cautions that we should look for.

Thanks for your help and appreciate your response.




Reply With Quote
  #3  
Old   
R. Pods
 
Posts: n/a

Default Re: ASA 9.0.2 database unload and reload - 10-31-2007 , 07:15 AM



We had to rebuild a good bunch of customer DBs when upgrading from 7.0
to 9.0. Our tests showed performance benefits, if we followed these 3 steps:
- create new DB (using dbinit)
- start iSQL on the new db and add pages up to expected rebuilt size
(ALTER DBSPACE xxx ADD nnnn MB)
- use dbunload -ii ... to load the everything into the newly created DB

An optional step in beetween would be reorganizing the new DB before
dbunload. Fast solution using CONTIG to defragment only then new db/log
(http://www.microsoft.com/technet/sys...sk/Contig.mspx)

Problems we encountered:
- stored procedures with duplicate variable declaration aborted unload
- view could not compiled (unknown reason; using -xi worked)
- one single error (corrupt data/index) aborts the whole process

Reimer

MD wrote:
Quote:
On one of our key ASA 9.0.2 databse ,we want to perform DBUnload and reload
operation.

The steps we outlined are as follows -

1) Make sure there are no connections / open transactions on the server
2) Unload the database
3) Create a new database using DBINIT
4) Defragment the drive
5) Load the database

I request your help in following -

1) In order to preserve current options set for the server and database and
apply to the newly created
database, is there any easy way to extract all settings of current
server/database ?
2) Which format of DBUnload you suggest, and, what are the benefits.
(ie. internal-internal or internal-external or external-internal or
external-external)
3) Are there any known issues or cautions that we should look for.

Thanks for your help and appreciate your response.



Reply With Quote
  #4  
Old   
Frank Ploessel
 
Posts: n/a

Default Re: ASA 9.0.2 database unload and reload - 10-31-2007 , 08:51 AM




On Wed, 31 Oct 2007 12:45:49 +0100, Stephen Rice
<"srice[at]sybase[dot]com"> wrote:

Quote:
1) dbunload automatically preserves all options you have set in the
database. The only thing you need to manage are the dbinit parameters.
dbunload -an manages those for you as well.
Hi,

We found that, depending on environment, but especially for a local db
engine, using unload/load to a file was up to three times faster than
piping the data from db to db without intermediate files. This may or may
not be an issue for you, however.

Frank



Reply With Quote
  #5  
Old   
MD
 
Posts: n/a

Default Re: ASA 9.0.2 database unload and reload - 10-31-2007 , 09:54 AM



Thanks to all of you for your help and support as well as
shaing your experiences, this is extremely helpful to me. I
will (ofcourse) take the backup before starting anything,
and, I plan to use -ii option while doing dbunload. I am
wary of using -ar because if the process fails, the existing
DB will be in an unknown state. I think it is safer to use
-ii option so that I have ability to create a new db with
new size, add space, do CONTIG, and then load it. If the
load fails, I will still have original DB intact without
needing to restore it from the backup. Ofcourse more disk
space will be needed, but that's ok. The DB is 15 GB, can
anyone estimate how long it would take for the entire
operation ? Also, appreciate if you have any comments on my
approach.




Quote:
On Wed, 31 Oct 2007 12:45:49 +0100, Stephen Rice
"srice[at]sybase[dot]com"> wrote:

1) dbunload automatically preserves all options you have
set in the database. The only thing you need to manage
are the dbinit parameters. dbunload -an manages those
for you as well.

Hi,

We found that, depending on environment, but especially
for a local db engine, using unload/load to a file was
up to three times faster than piping the data from db to
db without intermediate files. This may or may not be an
issue for you, however.

Frank


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.