status = STATUS.OPEN;
// OPEN BASIC SEGMENTS
int pos;
pos = registerDataSegment(new OStorageDataConfiguration(configuration, OStorage.DATA_DEFAULT_NAME));
dataSegments[pos].open();
pos = createClusterFromConfig(new OStoragePhysicalClusterConfiguration(configuration, OStorage.CLUSTER_INTERNAL_NAME,
clusters.length));
clusters[pos].open();
configuration.load();
pos = createClusterFromConfig(new OStoragePhysicalClusterConfiguration(configuration, OStorage.CLUSTER_INDEX_NAME,
clusters.length));
clusters[pos].open();
defaultClusterId = createClusterFromConfig(new OStoragePhysicalClusterConfiguration(configuration,
OStorage.CLUSTER_DEFAULT_NAME, clusters.length));
clusters[defaultClusterId].open();
// REGISTER DATA SEGMENT
for (int i = 0; i < configuration.dataSegments.size(); ++i) {
final OStorageDataConfiguration dataConfig = configuration.dataSegments.get(i);
pos = registerDataSegment(dataConfig);
if (pos == -1) {
// CLOSE AND REOPEN TO BE SURE ALL THE FILE SEGMENTS ARE
// OPENED