MUPIP REORG on a database file with non-zero RESERVED_BYTES retains structural integrity of file
Final Release Note
MUPIP REORG on a database file with non-zero RESERVED_BYTES retains the integrity of the database file. Previously, it was possible for cause a structurally damaged database file (for example DBINVGBL integrity error). [#349 (closed)]
Description
Below is a test case that demonstrates the issue. A MUPIP REORG fails with MUREORGFAIL error and the database ends up with DBINVGBL integrity error.
> cat reorg.csh
set verbose
setenv ydb_gbldir mumps.gld
rm mumps.gld; $ydb_dist/mumps -run GDE 'change -segment DEFAULT -block=4096'
rm mumps.dat; $ydb_dist/mupip create
$ydb_dist/mumps -run ^%XCMD 'set ^x=$j(1,62)'
$ydb_dist/mupip set -reserved=4012 -file mumps.dat
$ydb_dist/mupip integ mumps.dat
$ydb_dist/mupip reorg -reg "*" -fill=90
$ydb_dist/mupip integ mumps.dat
unset verbose
> source reorg.csh
.
.
$ydb_dist/mupip reorg -reg "*" -fill=90
Fill Factor:: Index blocks 90%: Data blocks 90%
Global: x (region DEFAULT)
%YDB-E-MUREORGFAIL, MUPIP REORG failed. Failure code: LLLL.
%YDB-I-GVIS, Global variable: ^x
$ydb_dist/mupip integ mumps.dat
Block:Offset Level
%YDB-E-DBINVGBL,
4:10 1 Invalid mixing of global names
Directory Path: 1:10, 2:10
Path: 4:10
Keys from ^x to the end are suspect.
%YDB-W-DBLOCMBINC,
0:0 FF Local bit map incorrect
%YDB-W-DBMRKBUSY,
3:0 FF Block incorrectly marked busy
%YDB-W-DBMRKBUSY,
5:0 FF Block incorrectly marked busy
Total error count from integ: 4.
.
.
Draft Release Note
MUPIP REORG on a database file with non-zero RESERVED_BYTES does not damage the integrity of the database file. Previously, it was possible for it to result in a broken database file (for example DBINVGBL integrity error).