Skip to main content

View configuration items

The following ways can be used to view parameters:

  • Use the SHOW statement to view parameters.

    You can view all configurations except the hidden configurations (those in _xx_xx format) and their attributes in the seekdb database. You can also view the value of a hidden configuration if it has been modified from the default value, by using the SHOW statement.

  • View the GV$OB_PARAMETERS view.

    Unlike the SHOW statement, you can query the GV$OB_PARAMETERS view to view all the parameters (including hidden parameters, those whose names start with an underscore (_)) and their attributes in a specified database.

View the configuration items by using the SHOW statement

You can view the value of the parameter by using the SHOW statement.

  1. Log in to seekdb.

    The following is the connection example. Please connect the database according to your actual environment.

    mysql -h127.xx.xx.xx -P2881 -uroot -p***** -A
  2. Run the following command to view the parameters:

    The statements are as follows:

    SHOW PARAMETERS [SHOW_PARAM_OPTS];

    Where:

    • You can specify [SHOW_PARAM_OPTS] as [LIKE 'pattern' | WHERE expr]. The column attributes specified in WHERE expr must be consistent with those returned in the SHOW PARAMETERS result.

    Here is an example of how to query a parameter.

    SHOW PARAMETERS LIKE '%syslog_level%';

    The query result is as follows:

    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    | name | data_type | value | info | edit_level | default_value | isdefault |
    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    | syslog_level | STRING | WDIAG | specifies the current level of logging. There are DEBUG, TRACE, WDIAG, EDIAG, INFO, WARN, ERROR, seven different log levels. | DEFAULT | DYNAMIC_EFFECTIVE | WDIAG | 1 |
    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    1 row in set

    The following table describes the meanings of the columns in the query result.

    Column NameDescription
    nameThe configuration item name.
    data_typeThe data type of the configuration parameter, which includes STRING and CAPACITY.
    valueThe value of the parameter.
    infoThe description of the configuration item.
    edit_levelDefines the behavior of modifying the parameter:
    • READONLY indicates that the parameter cannot be modified.
    • STATIC_EFFECTIVE indicates that the parameter can be modified, but the modification takes effect only after the SeekDB server is restarted.
    • DYNAMIC_EFFECTIVE indicates that the parameter can be modified, and the modification takes effect dynamically without restarting the SeekDB server.
    default_valueThe default value of the parameter.
    isdefaultIndicates whether the current value is the default value.
    • 0: The current value is not the default value.
    • 1: The current value is the default value.

Query the GV$OB_PARAMETERS view to view the parameters

  1. Log in to seekdb.

    A connection example is as follows. In actual use, refer to your environment.

    mysql -h127.xx.xx.xx -P2881 -uroot -p***** -A
  2. Run the following commands to enter the oceanbase database:

    USE oceanbase;
  3. Run the following command to view the configurations.

    The following query example shows how to execute this clause:

    SELECT * FROM GV$OB_PARAMETERS WHERE NAME LIKE '%syslog_level%';

    The query returns the following result:

    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    | NAME | DATA_TYPE | VALUE | INFO | EDIT_LEVEL | DEFAULT_VALUE | ISDEFAULT |
    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    | syslog_level | STRING | WDIAG | specifies the current level of logging. There are DEBUG, TRACE, WDIAG, EDIAG, INFO, WARN, ERROR, seven different log levels. | DYNAMIC_EFFECTIVE | WDIAG | YES |
    +--------------+-----------+-------+------------------------------------------------------------------------------------------------------------------------------+-------------------+---------------+-----------+
    1 row in set

For more information about the GV$OB_PARAMETERS view, see GV$OB_PARAMETERS (MySQL mode).