Note
This view is available starting with V2.2.77.
Purpose
This view displays the encryption status of tablespaces with encryption enabled in the current tenant.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| TABLESPACE_ID | bigint(20) | NO | The ID of the tablespace. |
| ENCRYPTIONALG | varchar(30) | NO | The name of the encryption algorithm. Valid values:
|
| ENCRYPTED | varchar(3) | NO | Indicates whether encryption is completed. Valid values:
|
| ENCRYPTEDKEY | varchar(33) | NO | The encryption key encrypted by the master key. |
| MASTERKEYID | bigint(20) unsigned | NO | The version of the master key. |
| BLOCKS_ENCRYPTED | decimal(20,0) | NO | The number of encrypted macroblocks. |
| BLOCKS_DECRYPTED | decimal(21,0) | NO | The number of unencrypted macroblocks. |
| STATUS | varchar(10) | NO | The encryption status. Valid values:
|
| CON_ID | bigint(20) | NO | The ID of the tenant. |
Sample query
Query the encryption status of tablespaces with encryption enabled in the current tenant.
obclient [oceanbase]> SELECT TABLESPACE_ID, ENCRYPTIONALG, ENCRYPTED, STATUS FROM oceanbase.V$ENCRYPTED_TABLESPACES;
The query result is as follows:
+---------------+---------------+-----------+--------+
| TABLESPACE_ID | ENCRYPTIONALG | ENCRYPTED | STATUS |
+---------------+---------------+-----------+--------+
| 500061 | aes-256 | YES | NORMAL |
+---------------+---------------+-----------+--------+
1 row in set
References
Query the encryption status of tables with encryption enabled in the current tenant: V$OB_ENCRYPTED_TABLES
For more information about data transparent encryption, see Data transparent encryption.
