This chapter describes how to configure HugePage for each operating system.
This section describes how to configure HugePage in Linux. Root permission is required.
Linux supports Transparent Huge Pages (THP), a capability to automatically increase the memory size according to the memory usage patterns in the OS.
THP allows not only shared memory but also process memory to run as HugePage, and this may affect the system performance. Therefore, it is recommended to disable the THP capability by setting the relevant kernel parameter to 'never'.
The following describes how to enable HugePage.
Check the size of HugePage supported in the current OS.
Check the user group ID that runs Tibero.
Apply the groups and number that will allocate HugePage in "/etc/sysctl.conf"
vm.nr_hugepages
Number of HugePages.
Size of TOTAL_SHM_SIZE / HugePage.
vm.hugetlb_shm_group
Group ID that will allocate HugePage.
User group ID that runs Tibero.
The following is an example of applying the kernel parameter when TOTAL_SHM_SIZE is set to 1024 MB and the size of HugePage supported by the current OS is 2 MB (2048 KB).
Apply the maximum locked memory value in "/etc/security/limits.conf".
memlock
HugePage size * number of HugePages
The following is an example of configuring the memlock value.
Restart the operating system.
The modified HugePage value has been applied.
Configure the Tibero initialization parameters in the configuration file (.tip).
TOTAL_SHM_SIZE
HugePage size * HugePage count
USE_HUGE_PAGE
Y
The following is an example of configuring the initialization parameters.
Restart the Tibero server.
To disable HugePage, restore the values that were modified to enable HugePage to their original values. The modified values can be restored by the same process and order used to enable HugePage.
AIX uses Large Page instead of HugePage. The benefits of using Large Page are similar to those of HugePage.
The following describes how to enable HugePage.
1. Change the Large Page configuration value of the OS.
AIX internally maintains physical memory pool sizes of 4 KB and 16 MB. The size of this pool can be changed to 16 MB by using the vmo command. The remaining space is automatically allocated to the 4 KB pool. From AIX 5.3 on, Large Page pools are dynamically maintained, so the system does not need to be restarted after changing the size.
First, v_pinshm must be separately configured so that the space in which the shared memory is allocated is not swapped to disk. percent_of_real_memory is the amount of memory that TSM possesses as a percentage of the total memory.
Configure the Large Page pool size. num_of_lage_pages is an integer and is equal to TSM / 16 MB.
2. Configure user permissions.
According to the security policy, all users (except the root user) must have the CAP_BYPASS_RAC_VMM permission to use Large Page. The permission can be configured by using the chuser command.
3. Configure the following Tibero initialization parameters in the environment configuration file (.tip).
TOTAL_SHM_SIZE
1 GB (Default value)
USE_HUGE_PAGE
Y
The following example configures the initialization parameters.
4. Restart the Tibero server.
To disable Large Page, restore the values that were modified to enable Large Page to their original values.
The functionality of HugePage can be applied by using the ISM (Intimate Shared Memory) function through Large Page.
The advantages of using ISM are as follows:
ISM shared memory is automatically locked by the OS when it is created. This ensures that the memory segment is not swapped to disk. It also allows the kernel to use a fast locking mechanism for I/O of the shared memory segment.
The memory structure used to convert the kernel's virtual memory address into a physical memory address is shared between multiple processes. This sharing reduces CPU consumption and conserves kernel memory space.
Large Page supported in the system's MMU (Memory Management Unit) is automatically allocated in the ISM memory segment. This allocation improves system performance by conserving memory space for managing pages and by simplifying virtual memory address conversion.
To enable HugePage, configure the server initialization parameter as follows.
The parameter is only valid in Solaris and the default value is Y.
If this function is turned on, shmget is used to create shared memory and the SHM_SHARED_MMU option is added when attaching with shmat. This function is only applied in the server process and the listener process. The client module that attaches the server's TSM does not use this option. However, if the parameter is not set to Y, change the value to Y and restart the Tibero server.
Set the server initialization parameter _USE_ISM to N and then restart the Tibero server.
Tibero does not restrict the size of HugePage, which can be set within the range allowed by different operating systems.
The recommended settings are as follows:
For small memory (less than 64GB): 4MB
For large memory (more than 64GB): 16MB
This chapter describes how to mount a CD-ROM for each platform.
The method for mounting a CD-ROM in AIX is as follows:
Log in as the root user.
Create a mount point to which a CD-ROM drive will be mounted.
Run the mount command.
The method for mounting a CD-ROM on Linux is as follows:
Check whether automounting is working.
Switch to a root user using the root account password.
Run the mount command
Run the unmount command.
The method for mounting a CD-ROM in Solaris is as follows:
1. Check the volume manager to verify whether a CD is recognized automatically.
If there is an existing CD, eject the CD.
3. Insert a CD and mount it with the following commands.
This chapter describes how to solve problems that can occur after Tibero is installed.
If the property TB_HOME is not set or is set improperly, or if the user configuration file is not applied after Tibero is installed, this message may be displayed when trying to connect to the tbSQL utility.
Check the TB_HOME property in the user configuration file, change the value if necessary, and then apply the file to the system.
If the property LD_LIBRARY_PATH is not set or is set improperly, or if the user configuration file is not applied after Tibero is installed, this message may be displayed when trying to connect to the tbSQL utility.
Check the LD_LIBRARY_PATH property in the user configuration file, change the value if necessary, and then apply the file to the system.
If TB_SID is not set, this message may be displayed when the tbboot or tbdown command is executed.
Check the TB_SID property in the user configuration file, change the value if necessary, and then apply the file to the system.
The following describes how to resolve issues that can occur after Tibero is installed in a TAC environment.
If a configuration file (.tip) cannot be found when a node is added, this message may be displayed.
Check whether the Tibero instance's $TB_SID.tip exists in the corresponding path by referring to TB_HOME and TB_SID.
To add a node, an existing node's setting values are necessary. If trying to access an existing node fails, this message may be displayed.
Check that TB_HOME and TB_SID are set properly.
Check that the existing node can be accessed through tbsql.
If an existing node does not work, start the node with the tbcm, tbboot commands then try to add the node again.
If transferring Tibero installation files to a new node fails, this message may be displayed.
Check whether the current node can access the node to be added using ping or ssh.
If the current node cannot access the node to be added, check the settings for account synchronization, networking, and any firewalls.
The SYSSUB tablespace, which contains TPR-related tables, was added starting from Tibero 5.0 r61295. During the system schema configuration portion of installing and patching, the syssub001.dtf file is automatically created in the directory $TB_ HOME/database/$TB_SID. However, if the property DB_CREATE_FILE_DEST is set to a specific location, the file is created at that location.
However, in an environment using a TAC raw device, the file is created on the local disk of the node processing the system schema. This results in an error that prevents other nodes from accessing the SYSSUB tablespace. The same error occurs in a shared disk environment when the property, DB_CREATE_FILE_DEST, is not set correctly.
Recreate the SYSSUB tablespace as follows:
Delete the existing tablespace.
Create a new tablespace.
Execute the following script.
This error occurs when the specified port number is already in use when executing the tbboot command.
The dbtimezone is the reference timezone value used for storing the timestamp with local timezone data to database. Since this value is internally processed in the database, it is not recommended to modify it, because this requires unnecessary operations leading to performance degradation.
This chapter describes the options of system.sh (vbs).
The following are the options that can be used with system.sh(vbs).
The following describes each option.
-h
Displays the help screen.
-p1 password
Enters the password of the SYS account. (Default value: tibero)
-p2 password
Enters the password of the SYSCAT account. (Default value: syscat)
-a1
Creates a system user and grant permissions. For the initial installation, select 'Y'.
Y: create a system user and grant permissions.
N: retain data.
-a2
Creates a table for a profile that can specify the database user password management policy. For the initial installation, select 'Y'.
Y: delete the existing table and create a new one.
N: retain data.
For more information about the profile, refer to "User Management and Database Security" in Tibero Administrator's Guide.
-a3
Registers a job schedule for collecting database object statistics. For the initial installation, it is recommended to select 'Y'.
Y: delete the job for statistics collection and then register.
N: do not register.
-a4
Creates TPR related tables for regular, automatic collection of statistics. Select 'Y' for the initial installation.
Y: delete the existing table and then create a new one.
N: retain data.
For more information about the APM, refer to "Tibero Performance Repository" in Tibero Administrator's Guide.
pkgonly
Executes only PSM built-in package scripts.
-sod
Divides the administrator role into 3 accounts for security purposes.
SYSSEC: Security Administrator
SYSAUD: System Auditor
SYSADM: System Administrator
(Default value: N, Not supported in Windows)
error
Prints error details in the terminal when an error occurs from a specific script while executing system.sh. (Not supported in Windows)
This chapter describes how to calculate the size of the undo tablespace.
If data is updated frequently in a system, a large volume of I/O happens in the undo tablespace. In such systems, data needs to be distributed by creating the undo tablespace with multiple data files.
The undo tablespace is automatically managed, providing the following advantages.
Helps design and manage efficiently with rollback capability and segments
Prevents undo data from being overwritten
Provides scalability
Supports Flashback queries
Consider the following when calculating the size of an undo tablespace.
Data file size, UNDO_RETENTION, and undo segments
Individual spaces in an undo segment are automatically managed, therefore you only need to set the minimum/maximum number of undo segments and the maximum size of a data file.
Set the minimum number of undo segments (USGMT_ONLINE_MIN) to 10 (default value). However, if there are too many concurrent transactions, overhead occurs to create additional undo segments. To decrease the overhead, set USGMT_ONLINE_MIN to the number of concurrent transactions.
If USGMT_ONLINE_MIN is greater than the number of existing undo segments, additional undo segments are created at boot time. USGMT_ONLINE_MIN can be set by node in TAC. For example, USGMT_ONLINE_MIN can be set to 30 and 40 for NODE1 and NODE2 respectively.
Set the maximum number of undo segments (USGMT_ONLINE_MAX).
Tibero automatically creates additional undo segments to prevent multiple transactions from sharing a single undo segment. However, the number of undo segments cannot exceed USGMT_ONLINE_MAX.
In TAC, a total number of Undo segments in all nodes cannot exceed USGMT_ONLINE_MAX. For example, if USGMT_ONLINE_MAX is set to 300 and the numbers of undo segments are 100 and 200 in NODE1 and NODE2 respectively, additional undo segments cannot be created in both nodes. Therefore, it is recommended to set USGMT_ONLINE_MAX to the number of maximum concurrent transactions.
The minimum size, expected size (based on the expected concurrent transactions count), and actual size of an undo tablespace can be calculated as follows. The expected size is used when a database is installed for the first time, and then the size can be checked based on the number of Undo blocks per second under the heaviest TPR load.
The following are the formulas for calculating the size of an undo tablespace.
Expected size
Actual size
The following describes each item in the formulas.
This chapter describes how to calculate the size of the shared memory.
The shared memory in Tibero is divided into fixed memory and shared pool memory as follows:
Fixed Memory Its size is fixed based on a parameter value set at database startup.
– Buffer cache (database buffer)
– Log buffer
– Others: space for global variables and managing working threads and session information.
Shared Pool Memory It is dynamically allocated during database operation.
– DD cache
– PP cache (library cache)
– Others
Consider the following when calculating the size of the shared memory.
The size of the shared memory cannot be increased dynamically while the database is running.
The size of the shared memory must be determined properly based on the usage patterns of the buffer cache and shared pool.
- Buffer Cache
Determine the size according to the Buffer Cache Hit rate in TPR after executing major workloads.
If the hit rate is lower than 90%, increase the buffer cache.
- Shared Pool Memory
Determine the size according to the SHARED POOL MEMORY item in v$sga after executing major workloads.
If the shared pool usage is too high (insufficient free area), increase the shared pool memory.
At least 1 MB of the shared pool memory is required for each session.
The size of each area in the shared memory can be checked with v$sga.
The size of the shared memory can be set and queried with the following initialization parameters.
The following example queries the size with the TOTAL_SHM_SIZE parameter.
The following example queries the size with the DB_CACHE_SIZE parameter.
Single mode : ⅔ of TOTAL_SHM_SIZE
TAC mode : ½ of TOTAL_SHM_SIZE
The following example queries the size with the LOG_BUFFER parameter. (the default value of LOG_BUFFER is 10 MB.)
The size can be calculated by subtracting the fixed memory size from the total shared memory size as follows:
Single mode The total shared pool size must be greater than _MIN_SHARED_POOL_SIZE.
TAC mode Sufficient space for Cluster Cache Control (CCC) and Cluster Wait-lock Service (CWS) is required. About 25% of a total buffer cache size is used by shared pools.
The shared pool space excluding space for CCC and CWS must be greater than
_MIN_SHARED_POOL_SIZE.
The free shared pool size for PP and DD caches must be greater than CCC and CWS spaces.
Universal
UTF8
8-bit International Standard Multilingual (Default
value)
UTF16
16-bit International Standard Multilingual
Korean
EUCKR
EUC 16-bit Korean
MSWIN949
MS Windows Code Page 949 Korean
English
ASCII
ASCII 7-bit English
Japanese
SJIS
SHIFT-JIS 16-bit Japanese
SJISTILDE
SHIFT-JIS 16-bit Japanese Including Fullwidth
Tilde
JA16SJIS
MS Windows Code Page 932 Japanese
JA16SJISTILDE
MS Windows Code Page 932 Japanese Including
Fullwidth Tilde
JA16EUC
EUC 24-bit Japanese
JA16EUCTILDE
EUC 24-bit Japanese
Chinese
GBK
MS Windows Code Page 936 Chinese
GB18030
Chinese National Standard GB18030-2000
Chinese, Hong Kong, Taiwanese
ZHT16HKSCS
HKSCS2001 Hong Kong
ZHT16BIG5
BIG5 Code Page Chinese
ZHT16MSWIN950
MS Windows Code Page 950 Chinese
EUCTW
EUC 32-bit Traditional Chinese
Vietnamese
VN8VN3
VN3 8-bit Vietnamese
Thai
TH8TISASCII
Thai Industrial Standard 620-2533 - ASCII 8-bit
Eastern European
EE8ISO8859P2
ISO8859-2 Eastern European
Western European
WE8MSWIN1252
MS Windows Code Page 1252 Western European
WE8ISO8859P1
ISO8859-1 Western European
WE8ISO8859P9
ISO8859-9 Western European (Turkish)
WE8ISO8859P15
ISO8859-15 Western European
Russian, Bulgarian
CL8MSWIN1251
MS Windows Code Page 1251 Cyrillic Script
CL8KOI8R
KOI8-R Cyrillic Script
CL8ISO8859P5
ISO8859-5 Cyrillic Script
RU8PC866
IBM-PC Code Page 866 8-bit Cyrillic Script
Greek
EL8ISO8859P7
ISO8859-7 Greek
EL8MSWIN1253
MS Windows Code Page 1253 8-bit Greek
Arabic
AR8ISO8859P6
ISO8859-6 Arabic
AR8MSWIN1256
MS Windows Code Page 1256 8-bit Arabic
Hebrew
IW8ISO8859P8
ISO8859-8 Hebrew
The minimum number of undo segments for each undo
tablespace
USGMT_ONLINE_MIN value for both single instance and TAC.
The maximum number of undo segments for each undo tablespace
Expected maximum number of concurrent transactions.
Single instance: USGMT_ONLINE_MAX value
TAC: USGMT_ONLINE_MAX / the number of nodes
_USGMT_UNIFORM_EXTSIZE
Size of an undo extent. An undo segment includes at least two undo extents.
Undo blocks per second
Number of undo blocks divided by a TPR interval (seconds). Use the value of undo blocks shown in Undo Statistic of TPR at the time under the heaviest load.
UNDO_RETENTION
Setting value in a tip file. (Default value: 900 seconds)
Margin
Preparative for irregularly long transactions (including INDEX rebuild). (Unit: KB)