Reducing data store size – Oracle Audio Technologies B31679-01 User Manual

Page 108

Advertising
background image

100

Oracle TimesTen In-Memory Database Installation Guide

Reducing data store size

Once a data store has been defined with a particular size for the
permanent partition (indicated by the

PermSize

DSN attribute), it

cannot be loaded at a smaller size, even if tables or rows are deleted. A
copy of the data store made with

ttBackup

also has the data store’s

permanent partition size embedded in it.

To reduce the allocated size of the permanent partition of a data store,
save a copy using the

ttMigrate

utility with the -

noRepUpgrade

option.

Then recreate the data store with a smaller permanent partition size and
restore the data.

Note: The permanent partition size of a data store cannot be reduced
below the size that is actually required by the data currently stored in the
data store. This value can be determined by querying the

perm_in_use_size

column of the table

sys.monitor

.

Perform these steps to reduce the permanent partition size of a data
store:

1.

Back up the old data store with

ttMigrate

-c

-

noRepUpgrade

.

2.

Create a new DSN definition for the new copy of the data store with a
smaller

PermSize

value.

3.

Restore the backup with

ttMigrate

-r -noRepUpgrade

.

Note: If you wish to use the original DSN rather than create a new one
in Step 2, then you must first destroy the original data store files using
the

ttDestroy

utility.

Here are the steps to reduce a data store’s allocated size from 400 MB to
100 MB. The data store is in

/ds/Sales/Data

and has the Data Source

Name (DSN)

salesdata

.

1.

ttMigrate -c DSN=salesdata -noRepUpgrade /tmp/salesbackup

2.

ttDestroy /ds/Sales/Data

3.

Update the DSN

salesdata

to have a size of 100 MB. See

"Changing

data store size"

in the

Oracle TimesTen In-Memory Database

Operations Guide

.

4.

ttMigrate -r "DSN=salesdata;AutoCreate=1" -noRepUpgrade

/tmp/salesbackup

Advertising