Kbase 20339: How Parameter -Bt Works With Temp-Tables?
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  1/27/2010 |
|
Status: Verified
GOAL:
How the -Bt parameter works with temp-tables?
GOAL:
How the -tmpbsize works with temp-tables?
GOAL:
How much memory does the -Bt parameter take?
GOAL:
What block size do temp-tables use?
FACT(s) (Environment):
All Supported Operating Systems
Progress/OpenEdge Versions
FIX:
The -Bt parameter is a client performance parameter that specifies the size of the buffer pool for blocks or records from the temporary table.
The client uses the single user database management code (-1, -i, and -Bt) to work with temporary tables. If -Bt is defined high enough to fit all of the temp-tables, the temporary files are not used to get the temp-table records.
In Progress 9.0x and earlier, the temporary tables database uses the default database block size of the client's platform, and the -Bt parameter uses the same unit: if the client runs on Win32, the allocation is made using 4Kb units; on most UNIX systems, it uses 1Kb units. Because the default database block size is 1, 2, or 4Kb depending on platform, 32 records per block is used to store the records in a temp-table data block.
In Progress 9.1x up to 9.1D06 inclusive, the temporary tables database uses a database block size of 8Kb and 128 records per block on all platform. However, the unit for -Bt has been left unchanged, otherwise pre-9.1 applications would have suddenly increased their memory needs by up to 8 times when migrating to 9.1x (for example, if we changed the unit for -Bt, on UNIX "-Bt 1000" would have gone from taking around 1Mb per client in 9.0B to taking around 8Mb per client in 9.1A !).
Therefore the amount specified by -Bt is still multiplied by 4Kb on Win32 platforms, and by 1Kb on UNIX platforms; the figure is then rounded down to the nearest 8Kb boundary. Therefore, for version 9.1A to 9.1D06:
-Bt Kb usage Kb usage
setting on Win32 on UNIX
------- -------- --------
25 96 24
100 400 96
200 800 200
In version 9.1D07 and OpenEdge 10.x, a new startup option was introduced that allows to specify what block size temporary tables will use: -tmpbsize.
Possible values are 1, 4 and 8,which set block sizes of 1024, 4096 and 8192 respectively. Examples:
-tmpbsize 1 -tmpbsize 4 (starting in OpenEdge 10.1B) -tmpbsize 8
The default value is version dependent. Values other than 1, 4 or 8 will be accepted at start-up, but will be silently reset to either 1, 4 or 8.
When -tmpbsize is set to 1, the temporary tables database will store up to 32 records per block; when -tmpbsize is set to 8, the temporary tables database will store up to 256 records per block.
In addition to that, -Bt now uses the same unit as -tmpbsize, which is consistent with the -B database parameter. Examples:
Kb usage
-Bt -tmpbsize on all
setting setting platforms
------- --------- ---------
25 8 200
100 1 100
200 none 200
Starting with version 10.1B the tmpbsize has three options;1, 4, and 8. The default went to 4 from the previous default of 1.
Starting with version 10.1A the -Bt default went from 10 to 255 with minimum at 10.