remove add bi

por | 14 mayo, 2014

This Process is only valid for Versions 9.x and higher where it is possible to have a total bi file size greater than 2 GB.

1. Take a Progress backup of the database as it is now. Use the PROBKUP command with the -norecover parameter.
probkup db-name destination-device -norecover

If there is enough space to restore the database to a new location then do so. The current database will serve as a backup if the PROBKUP that was taken turns out to be bad for some reason. Otherwise if a known good backup does not exist and there is not enough disk space to retain the original database, it is highly recommended that after the backup is completed a verify be performed. The verify will ensure the backup is good prior to deleting the current database. If the backup turns out to be bad and the database is deleted there would be no way to recover.

With a known verified good backup of the database, the current database must be deleted if there are space constraints. Use the prodel command to remove the database.

prodel db-name

2. Create a file with 2 additional bi extents. If the current configuration has only one variable bi extent the new .st file will have 3 bi extents, 2 fixed at 2 GB each and 1 variable extent.

3. Restore the database using the file.
prorest dbname backup_db_file_name

4. Start the database in single user mode to go through crash recovery.

5. When crash recovery completes successfully the database is ready for use however, it is not recommended to run with bi extents sizes of 2 GB.

6. Truncate the bi file.
proutil db-name -C truncate bi

7. Remove all bi files using the following command.
prostrct remove db-name bi

Execute this command once for each bi extent to be removed. The last or variable extent is the first extent removed.

8. Once the bi extents are removed, create an file to add bi extents of the proper size and number. One fixed extent slightly larger than the normal bi file size plus one variable extent is all that is needed. Use the prostrct add command with the, to add the desired bi extents.
prostrct add db-name

9. Database is ready for use with proper size and number of bi extents.