1.1.1

Table Of Contents
2. Create the disk store that you want to use for persisting the table's data, or use the default disk store. See
Creating a Disk Store or Using the Default on page 86.
3. Specify table persistence and the named disk store in the CREATE TABLE statement. For example:
CREATE TABLE Orders(OrderId INT NOT NULL,ItemId INT )
persistent 'OrdersDiskStore' asynchronous
This example uses asynchronous writes to persist table data to the "OrdersDiskStore."
Note: Persistent tables must be associated with a disk store. If you do not specify a named disk store
in the CREATE TABLE statement, SQLFire persists the table to the default disk store. For example,
the following statement persists the new table to the default disk store:
CREATE TABLE Orders(OrderId INT NOT NULL,ItemId INT )
persistent asynchronous
Note: When you specify asynchronous persistence, asynchronous writes to the disk store use certain
disk store attributes. See Disk Store Persistence Attributes on page 81.
Related Topics
CREATE DISKSTORE on page 480
CREATE TABLE on page 491
Evicting table data from memoryUse eviction to remove table data from memory, or to persist the overow data in a disk store.
Optimizing Availability and Performance
Be aware of what you can do to optimize availability and performance of disk stores.
Consider these guidelines:
When you start your system, start all the members that have persistent tables in parallel. Create and use startup
scripts for consistency and completeness.
Shut down your system using the sqlf shut-down-all command. This is an ordered shutdown that shuts
down all data stores and accessors, but leaves locators and JMX agents running. When shutting down an entire
system, a locator should be the last member to shut down (after all data stores have successfully stopped).
Decide on a le compaction policy and, if needed, develop procedures to monitor your les and execute regular
compaction.
Decide on a backup strategy for your disk stores and follow it. You can back up by copying the les while the
system is ofine, or you can back up an online system using the sqlf backup command.
If you drop or alter any persistent table while your disk store is ofine, consider synchronizing the tables in
your disk stores.
Starting System with Disk Stores
When you shut down a member that persists data, the data remains in the disk store les, available to be reloaded
when the member starts up again. Keep in mind that peer clients are dependent on locators or data store members
to persist data, as they cannot persist data on their own.
The following sections explain what happens during startup and shutdown:
Shutdown: Most Recent Data from the Last Run on page 87
Startup Process on page 88
Example Startup Scenarios on page 89
87
Using Disk Stores to Persist Data