資源類型
InnoDBCluster
表 8.1 InnoDBCluster 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
apiVersion | 字串 | mysql.oracle.com/v2 | 是 |
kind | 字串 | InnoDBCluster | 是 |
metadata | 物件 | 請參閱 Kubernetes API 文件 | 是 |
spec |
物件 | 是 | |
status |
物件 | 否 |
InnoDBCluster.spec
表 8.2 InnoDBCluster.spec 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
secretName |
字串 | 包含 root/預設帳戶密碼的通用類型 Secret 名稱 |
是 |
backupProfiles |
[]物件 | 叢集的備份設定檔規格,可以從備份排程和一次性備份作業中參考 |
否 |
backupSchedules |
[]物件 | 定期執行備份的排程 |
否 |
baseServerId |
整數 |
叢集中執行個體的 MySQL server_id 的基礎值
|
否 |
datadirVolumeClaimTemplate |
物件 | PersistentVolumeClaim 的範本,用作 datadir |
否 |
edition |
字串 | MySQL 伺服器版本 (社群版或企業版) |
否 |
imagePullPolicy |
字串 | 預設為 Always,但在部署 Operator 時,於 deploy-operator.yaml 中設定為 IfNotPresent |
否 |
imagePullSecrets |
[]物件 | 否 | |
imageRepository |
字串 | 從中提取映像檔的儲存庫;預設為 container-registry.oracle.com/mysql |
否 |
initDB |
物件 | 否 | |
instances |
整數 |
叢集的 MySQL 複本執行個體數
|
否 |
keyring |
物件 | 金鑰環規格 |
否 |
logs |
物件 | MySQL Operator for Kubernetes 8.2.0-2.1.1 中新增的功能。 | 否 |
metrics |
物件 | Prometheus 風格指標提供者的設定;在 Kubernetes 的 MySQL Operator 8.1.0-2.1.0 中新增的功能。 |
否 |
mycnf |
字串 | my.cnf 的自訂設定新增項目 |
否 |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 | |
podSpec |
物件 | 否 | |
readReplicas |
[]物件 | 否 | |
router |
物件 | MySQL Router 規格 |
否 |
service |
物件 | 用於連線至 InnoDB Cluster 的應用程式所使用的服務設定 |
否 |
serviceAccountName |
字串 | 否 | |
serviceFqdnTemplate |
字串 | 解析為叢集無頭執行個體服務和個別 Pod 的 FQDN 範本;在 Kubernetes 的 MySQL Operator 8.4.0-2.1.3 中新增的功能。 |
否 |
tlsCASecretName |
字串 | 包含 CA (ca.pem) 和 SSL 可選 CRL (crl.pem) 的通用類型 Secret 名稱 |
否 |
tlsSecretName |
字串 | 包含 SSL 伺服器憑證和私密金鑰的 TLS 類型 Secret 名稱 |
否 |
tlsUseSelfSigned |
布林值 |
啟用自我簽署 TLS 憑證的使用,以減少或停用基於 TLS 的安全性驗證
|
否 |
version |
字串 | MySQL 伺服器版本 |
否 |
InnoDBCluster.spec.backupProfiles[index]
表 8.3 InnoDBCluster.spec.backupProfiles[index] 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
name |
字串 | 內嵌備份設定檔,在其他地方稱為 backupProfileName |
是 |
dumpInstance |
物件 | 否 | |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 | |
snapshot |
物件 | 否 |
InnoDBCluster.spec.backupProfiles[index].dumpInstance
表 8.4 InnoDBCluster.spec.backupProfiles[index].dumpInstance 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
dumpOptions |
物件 | 直接傳遞至 MySQL Shell 的 DumpInstance() 的鍵值組字典 |
否 |
storage |
物件 | 否 |
InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage
表 8.5 InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
azure |
物件 | 否 | |
ociObjectStorage |
物件 | 否 | |
persistentVolumeClaim |
物件 | 要使用的 PVC 規格。在執行備份的 Pod 中「按原樣」使用。 |
否 |
s3 |
物件 | 否 |
InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.azure
表 8.6 InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.azure 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
config |
字串 | 具有 Azure BLOB 儲存體設定和認證的 Secret 名稱 |
是 |
containerName |
字串 | 儲存 Dump 的 Azure BLOB 儲存體容器名稱 |
是 |
prefix |
字串 | 容器中儲存 Dump 檔案的路徑 |
否 |
InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.ociObjectStorage
表 8.7 InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.ociObjectStorage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存備份的 OCI 儲存桶名稱 |
是 |
credentials |
字串 | 具有存取儲存桶資料的 Secret 名稱 |
是 |
prefix |
字串 | 儲存備份的儲存桶路徑 |
否 |
InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.s3
表 8.8 InnoDBCluster.spec.backupProfiles[index].dumpInstance.storage.s3 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 Dump 的 S3 儲存桶名稱 |
是 |
config |
字串 | 具有 S3 設定和認證的 Secret 名稱 |
是 |
endpoint |
字串 | 覆寫端點 URL |
否 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
否 |
profile |
字串 |
設定檔正在設定檔中使用的設定檔
|
否 |
InnoDBCluster.spec.backupProfiles[index].snapshot
InnoDBCluster.spec.backupProfiles[index].snapshot.storage
表 8.10 InnoDBCluster.spec.backupProfiles[index].snapshot.storage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
azure |
物件 | 否 | |
ociObjectStorage |
物件 | 否 | |
persistentVolumeClaim |
物件 | 要使用的 PVC 規格。在執行備份的 Pod 中「按原樣」使用。 |
否 |
s3 |
物件 | 否 |
InnoDBCluster.spec.backupProfiles[index].snapshot.storage.azure
表 8.11 InnoDBCluster.spec.backupProfiles[index].snapshot.storage.azure 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
config |
字串 | 具有 Azure BLOB 儲存體設定和認證的 Secret 名稱 |
是 |
containerName |
字串 | 儲存 Dump 的 Azure BLOB 儲存體容器名稱 |
是 |
prefix |
字串 | 容器中儲存 Dump 檔案的路徑 |
否 |
InnoDBCluster.spec.backupProfiles[index].snapshot.storage.ociObjectStorage
表 8.12 InnoDBCluster.spec.backupProfiles[index].snapshot.storage.ociObjectStorage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存備份的儲存桶名稱 |
是 |
credentials |
字串 | 具有存取儲存桶資料的 Secret 名稱 |
是 |
prefix |
字串 | 儲存備份的儲存桶路徑 |
否 |
InnoDBCluster.spec.backupProfiles[index].snapshot.storage.s3
表 8.13 InnoDBCluster.spec.backupProfiles[index].snapshot.storage.s3 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 Dump 的 S3 儲存桶名稱 |
是 |
config |
字串 | 具有 S3 設定和認證的 Secret 名稱 |
是 |
endpoint |
字串 | 覆寫端點 URL |
否 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
否 |
profile |
字串 |
設定檔正在設定檔中使用的設定檔
|
否 |
InnoDBCluster.spec.backupSchedules[index]
表 8.14 InnoDBCluster.spec.backupSchedules[index] 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
name |
字串 | 備份排程的名稱 |
是 |
schedule |
字串 | 作業的排程,語法為 cron 表達式 |
是 |
backupProfile |
物件 | 如果未指定 backupProfileName,則為 backupProfile 規格 |
否 |
backupProfileName |
字串 | 要使用的 backupProfile 名稱 |
否 |
deleteBackupData |
布林值 |
如果刪除作業建立的 MySQLBackup 物件,是否要刪除備份資料
|
否 |
enabled |
布林值 |
是否啟用排程
|
否 |
timeZone |
字串 | 備份排程的時區,例如:'America/New_York' -- Kubernetes 的 MySQL Operator 8.3.0-2.1.2 中新增的功能。 |
否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile
描述:如果未指定 backupProfileName,則為 backupProfile 規格
表 8.15 InnoDBCluster.spec.backupSchedules[index].backupProfile 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
dumpInstance |
物件 | 否 | |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance
表 8.16 InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
dumpOptions |
物件 | 直接傳遞至 MySQL Shell 的 DumpInstance() 的鍵值組字典 |
否 |
storage |
物件 | 否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage
表 8.17 InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
azure |
物件 | 否 | |
ociObjectStorage |
物件 | 否 | |
persistentVolumeClaim |
物件 | 要使用的 PVC 規格。在執行備份的 Pod 中「按原樣」使用。 |
否 |
s3 |
物件 | 否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.azure
表 8.18 InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.azure 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
config |
字串 | 具有 Azure BLOB 儲存體設定和認證的 Secret 名稱 |
是 |
containerName |
字串 | 儲存 Dump 的 Azure BLOB 儲存體容器名稱 |
是 |
prefix |
字串 | 容器中儲存 Dump 檔案的路徑 |
否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.ociObjectStorage
表 8.19 InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.ociObjectStorage 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存備份的 OCI 儲存桶名稱 |
是 |
credentials |
字串 | 具有存取儲存桶資料的 Secret 名稱 |
是 |
prefix |
字串 | 儲存備份的儲存桶路徑 |
否 |
InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.s3
表 8.20 InnoDBCluster.spec.backupSchedules[index].backupProfile.dumpInstance.storage.s3 的 Spec 表格
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 Dump 的 S3 儲存桶名稱 |
是 |
config |
字串 | 具有 S3 設定和認證的 Secret 名稱 |
是 |
endpoint |
字串 | 覆寫端點 URL |
否 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
否 |
profile |
字串 |
設定檔正在設定檔中使用的設定檔
|
否 |
InnoDBCluster.spec.imagePullSecrets[index]
InnoDBCluster.spec.initDB
InnoDBCluster.spec.initDB.clone
表 8.23 InnoDBCluster.spec.initDB.clone 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
donorUrl |
字串 | 要從中複製的叢集 URL |
是 |
secretKeyRef |
物件 | 是 | |
rootUser |
字串 |
用於複製的使用者名稱
|
否 |
InnoDBCluster.spec.initDB.clone.secretKeyRef
表 8.24 InnoDBCluster.spec.initDB.clone.secretKeyRef 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
name |
字串 | 具有金鑰 'rootPassword' 的 Secret 名稱,用於儲存 rootUser 中指定使用者的密碼 |
是 |
InnoDBCluster.spec.initDB.dump
表 8.25 InnoDBCluster.spec.initDB.dump 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
storage |
物件 | 是 | |
name |
字串 | Dump 的名稱。運算子不會使用,但為叢集管理員提供描述性提示 |
否 |
options |
物件 | 直接傳遞到 MySQL Shell 的 loadDump() 的鍵值對字典 |
否 |
path |
字串 | PVC 中 dump 的路徑。在指定 persistentVolumeClaim 時使用。若為 ociObjectStorage、S3 或 azure 則省略。 |
否 |
InnoDBCluster.spec.initDB.dump.storage
表 8.26 InnoDBCluster.spec.initDB.dump.storage 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
azure |
物件 | 否 | |
ociObjectStorage |
物件 | 否 | |
persistentVolumeClaim |
物件 | 要使用的 PVC 規格。在複製 Pod 中「按原樣」使用。 |
否 |
s3 |
物件 | 否 |
InnoDBCluster.spec.initDB.dump.storage.azure
表 8.27 InnoDBCluster.spec.initDB.dump.storage.azure 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
config |
字串 | 具有 Azure BLOB 儲存體設定和認證的 Secret 名稱 |
是 |
containerName |
字串 | 儲存 Dump 的 Azure BLOB 儲存體容器名稱 |
是 |
prefix |
字串 | 容器中儲存 Dump 檔案的路徑 |
是 |
InnoDBCluster.spec.initDB.dump.storage.ociObjectStorage
表 8.28 InnoDBCluster.spec.initDB.dump.storage.ociObjectStorage 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 dump 的 OCI 儲存桶名稱 |
是 |
credentials |
字串 | 具有存取儲存桶資料的 Secret 名稱 |
是 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
是 |
InnoDBCluster.spec.initDB.dump.storage.s3
表 8.29 InnoDBCluster.spec.initDB.dump.storage.s3 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 Dump 的 S3 儲存桶名稱 |
是 |
config |
字串 | 具有 S3 設定和認證的 Secret 名稱 |
是 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
是 |
endpoint |
字串 | 覆寫端點 URL |
否 |
profile |
字串 |
設定檔正在設定檔中使用的設定檔
|
否 |
InnoDBCluster.spec.keyring
描述:金鑰環規格
表 8.30 InnoDBCluster.spec.keyring 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
encryptedFile |
物件 | 金鑰環「加密檔案」規格 |
否 |
file |
物件 | 金鑰環「檔案」規格 |
否 |
oci |
物件 | 金鑰環「OCI」規格 |
否 |
InnoDBCluster.spec.keyring.encryptedFile
描述:金鑰環「加密檔案」規格
表 8.31 InnoDBCluster.spec.keyring.encryptedFile 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
password |
字串 | 具有金鑰環密碼的金鑰 'keyring_password' 的 Secret 名稱 |
是 |
storage |
物件 | 要掛載金鑰環檔案所在位置的磁碟區規格 |
是 |
fileName |
字串 |
儲存磁碟區內金鑰環檔案名稱的路徑(會加上掛載路徑前綴)
|
否 |
readOnly |
布林值 |
是否以唯讀模式開啟金鑰環檔案
|
否 |
InnoDBCluster.spec.keyring.file
描述:金鑰環「檔案」規格
表 8.32 InnoDBCluster.spec.keyring.file 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
storage |
物件 | 要掛載金鑰環檔案所在位置的磁碟區規格 |
是 |
fileName |
字串 |
儲存磁碟區內金鑰環檔案名稱的路徑(會加上掛載路徑前綴)
|
否 |
readOnly |
布林值 |
是否以唯讀模式開啟金鑰環檔案
|
否 |
InnoDBCluster.spec.keyring.oci
描述:金鑰環「OCI」規格
表 8.33 InnoDBCluster.spec.keyring.oci 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
keyFingerprint |
字串 | 私密金鑰指紋 |
是 |
keySecret |
字串 | 在欄位 'privatekey' 下包含私密金鑰的 Secret |
是 |
tenancy |
字串 | 租用戶識別碼,格式為 ocid1.tenancy.oc1... |
是 |
user |
字串 | 使用者識別碼,格式為 ocid1.user.oc1... |
是 |
caCertificate |
字串 | 包含 ca.crt 欄位的 Secret,其中包含 keyring_oci 外掛程式用於 Oracle Cloud Infrastructure 憑證驗證的 CA 憑證套件檔案 |
否 |
compartment |
字串 | 區間識別碼,格式為 ocid1.compartment.oc1... |
否 |
endpoints |
物件 | 否 | |
masterKey |
字串 | 格式為 ocid1.key.oc1... 的主金鑰識別碼 |
否 |
virtualVault |
字串 | 格式為 ocid1.vault.oc1... 的 Vault 識別碼 |
否 |
InnoDBCluster.spec.keyring.oci.endpoints
表 8.34 InnoDBCluster.spec.keyring.oci.endpoints 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
encryption |
字串 | 加密端點 URI,如 {identifier}-crypto.kms.{region}.oraclecloud.com |
否 |
management |
字串 | 管理端點 URI,如 {identifier}-management.kms.{region}.oraclecloud.com |
否 |
secrets |
字串 | 秘密端點 URI,如 secrets.vaults.{region}.oci.oraclecloud.com |
否 |
vaults |
字串 | Vault 端點 URI,如 vaults.{region}.oci.oraclecloud.com |
否 |
InnoDBCluster.spec.logs
MySQL Operator for Kubernetes 8.2.0-2.1.1 中新增的功能。
InnoDBCluster.spec.logs.collector
表 8.36 InnoDBCluster.spec.logs.collector 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
containerName |
字串 |
收集器容器 Sidecar 的名稱
|
否 |
env |
[]物件 | 否 | |
fluentd |
物件 | fluentd 日誌收集器的屬性 |
否 |
image |
字串 | 用於日誌收集器 Sidecar 的映像檔名稱,包括登錄檔和儲存庫。如果提供,它需要是設定收集器類型的映像檔。 |
否 |
InnoDBCluster.spec.logs.collector.fluentd
描述:fluentd 日誌收集器的屬性
表 8.37 InnoDBCluster.spec.logs.collector.fluentd 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
additionalFilterConfiguration |
字串 | 要新增到組態檔案的額外 Fluentd 篩選器的原始組態 |
否 |
errorLog |
物件 | 否 | |
generalLog |
物件 | 否 | |
recordAugmentation |
物件 | 否 | |
sinks |
[]物件 | 否 | |
slowQueryLog |
物件 | 否 |
InnoDBCluster.spec.logs.collector.fluentd.errorLog
表 8.38 InnoDBCluster.spec.logs.collector.fluentd.errorLog 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
options |
物件 | 錯誤日誌的 fluentd 特定選項 |
否 |
tag |
字串 |
錯誤日誌記錄的標籤
|
否 |
InnoDBCluster.spec.logs.collector.fluentd.generalLog
表 8.39 InnoDBCluster.spec.logs.collector.fluentd.generalLog 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
options |
物件 | 一般日誌的 fluentd 特定選項 |
否 |
tag |
字串 |
一般日誌記錄的標籤
|
否 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation
表 8.40 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
annotations |
[]物件 | 否 | |
enabled |
布林值 |
是否啟用額外資料的記錄增強
|
否 |
labels |
[]物件 | 否 | |
podFields |
[]物件 | 否 | |
resourceFields |
[]物件 | 否 | |
staticFields |
[]物件 | 否 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.annotations[index]
表 8.41 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.annotations[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
annotationName |
字串 | 保留要儲存在日誌記錄中 fieldName 下的值的 Pod 標籤名稱 |
是 |
fieldName |
字串 | 新增到日誌記錄的欄位名稱,其值來自 annotationName |
是 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.labels[index]
表 8.42 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.labels[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
fieldName |
字串 | 新增到日誌記錄的欄位名稱,其值來自 labelName |
是 |
labelName |
字串 | 保留要儲存在日誌記錄中 fieldName 下的值的 Pod 標籤名稱 |
是 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.podFields[index]
表 8.43 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.podFields[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
fieldName |
字串 | 新增到日誌記錄的欄位名稱,其值取自儲存在 fieldPath 中路徑的欄位 |
是 |
fieldPath |
字串 | 欄位 fieldName 的值。路徑應與從欄位參考掛載環境變數所使用的語法相同 - valueFrom.fieldRef.fieldPath。欄位將掛載到 Pod 作為環境變數,加上前綴,然後新增到日誌記錄。欄位參考的範例為:spec.nodeName、metadata.namespace、status.podIP 等。 |
是 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.resourceFields[index]
表 8.44 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.resourceFields[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
containerName |
字串 | 是 | |
fieldName |
字串 | 新增到日誌記錄的欄位名稱,其值取自儲存在 fieldPath 中路徑的欄位 |
是 |
resource |
字串 | 請參閱 https://kubernetes.dev.org.tw/docs/tasks/inject-data-application/environment-variable-expose-pod-information/#use-container-fields-as-values-for-environment-variables |
是 |
InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.staticFields[index]
表 8.45 InnoDBCluster.spec.logs.collector.fluentd.recordAugmentation.staticFields[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
fieldName |
字串 | 新增到日誌記錄的欄位名稱,其值來自 fieldValue |
是 |
fieldValue |
字串 | 靜態欄位的值,其名稱取自 fieldName |
是 |
InnoDBCluster.spec.logs.collector.fluentd.sinks[index]
表 8.46 InnoDBCluster.spec.logs.collector.fluentd.sinks[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
name |
字串 | Sink 的名稱。僅用於文件用途 |
是 |
rawConfig |
字串 | Sink 的原始組態 |
是 |
InnoDBCluster.spec.logs.collector.fluentd.slowQueryLog
表 8.47 InnoDBCluster.spec.logs.collector.fluentd.slowQueryLog 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
options |
物件 | 慢速日誌的 fluentd 特定選項 |
否 |
tag |
字串 |
慢速日誌記錄的標籤
|
否 |
InnoDBCluster.spec.logs.error
表 8.48 InnoDBCluster.spec.logs.error 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
collect |
布林值 |
是否應收集錯誤記錄資料。表示應啟用記錄。如果啟用,錯誤日誌將切換為 JSON 格式輸出
|
否 |
verbosity |
整數 |
記錄錯誤詳細程度。如需詳細資訊,請參閱 MySQL Server --log-error-verbosity 文件。
|
否 |
InnoDBCluster.spec.logs.general
表 8.49 InnoDBCluster.spec.logs.general 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
collect |
布林值 |
是否應收集一般記錄資料。表示應啟用記錄。
|
否 |
enabled |
布林值 |
是否應啟用一般記錄
|
否 |
InnoDBCluster.spec.logs.slowQuery
表 8.50 InnoDBCluster.spec.logs.slowQuery 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
collect |
布林值 |
是否應收集慢速查詢記錄資料。表示應啟用記錄。
|
否 |
enabled |
布林值 |
是否應啟用慢速查詢記錄
|
否 |
longQueryTime |
number |
慢速查詢時間閾值
|
否 |
InnoDBCluster.spec.metrics
描述:Prometheus 風格度量提供者的組態;在 Kubernetes 8.1.0-2.1.0 的 MySQL Operator 中新增的功能。
表 8.51 InnoDBCluster.spec.metrics 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
enable |
布林值 |
切換以啟用或停用度量 Sidecar
|
是 |
image |
字串 | 用於度量 Sidecar 的映像檔名稱,如果提供,則將啟用度量 |
是 |
monitor |
布林值 |
為 Prometheus Operator 建立 ServiceMonitor
|
否 |
monitorSpec |
物件 |
ServiceMonitor 物件的自訂組態
|
否 |
options |
[]string | 作為命令列引數傳遞給度量提供者的選項 |
否 |
tlsSecret |
字串 | 具有 TLS 憑證、金鑰和 CA 的 Secret 名稱,將掛載在容器的 /tls 中,並且可以從 webConfig 使用 |
否 |
webConfig |
字串 | 具有 web.config 檔案的 ConfigMap 名稱,如果提供此選項,則會新增命令列選項 --web.config.file |
否 |
InnoDBCluster.spec.readReplicas[index]
MySQL Operator for Kubernetes 8.2.0-2.1.1 中新增的功能。
表 8.52 InnoDBCluster.spec.readReplicas[index] 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
baseServerId |
整數 |
讀取複本執行個體的 MySQL server_id 的基本值,如果為 0,則會自動指派
|
是 |
name |
字串 | 是 | |
datadirVolumeClaimTemplate |
物件 | PersistentVolumeClaim 的範本,用作 datadir |
否 |
instances |
整數 |
讀取複本集合的 MySQL 執行個體數
|
否 |
mycnf |
字串 | my.cnf 的自訂設定新增項目 |
否 |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 | |
podSpec |
物件 | 否 | |
version |
字串 | MySQL 伺服器版本 |
否 |
InnoDBCluster.spec.router
描述:MySQL Router 規格
表 8.53 InnoDBCluster.spec.router 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bootstrapOptions |
[]string | 在引導時傳遞到 MySQL Router 的命令列選項;在 Kubernetes 8.2.0-2.1.1 的 MySQL Operator 中新增的功能。 |
否 |
instances |
整數 |
要部署的 MySQL Router 執行個體數
|
否 |
options |
[]string | 在執行時傳遞到 MySQL Router 的命令列選項;在 Kubernetes 8.2.0-2.1.1 的 MySQL Operator 中新增的功能。 |
否 |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 | |
podSpec |
物件 | 否 | |
routingOptions |
物件 | 設定叢集的路由選項 |
否 |
tlsSecretName |
字串 | 包含用於 SSL 的 MySQL Router 憑證和私密金鑰的 TLS 類型 Secret 名稱 |
否 |
version |
字串 | 覆寫 MySQL Router 版本 |
否 |
InnoDBCluster.spec.router.routingOptions
描述:設定叢集的路由選項
表 8.54 InnoDBCluster.spec.router.routingOptions 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
invalidated_cluster_policy |
enum |
|
否 |
read_only_targets |
enum |
|
否 |
stats_updates_frequency |
整數 |
|
否 |
InnoDBCluster.spec.service
描述:應用程式連線到 InnoDB Cluster 時所使用的服務設定
表 8.55 InnoDBCluster.spec.service 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
annotations |
物件 | 服務的自訂註解 |
否 |
defaultPort |
enum |
服務預設 (3306) 連接埠的目標。如果 mysql-rw 流量將導向主節點並允許讀取和寫入操作,mysql-ro 流量將導向複本節點並僅允許讀取操作,而 mysql-rw-split 則會將路由器的讀寫分割作為目標
|
否 |
labels |
物件 | 服務的自訂標籤 |
否 |
type |
enum |
|
否 |
MySQLBackup
MySQLBackup.spec
表 8.57 MySQLBackup.spec 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
clusterName |
字串 | 是 | |
addTimestampToBackupDirectory |
布林值 |
|
否 |
backupProfile |
物件 | 如果未指定 backupProfileName,則為 backupProfile 規格 |
否 |
backupProfileName |
字串 | 否 | |
deleteBackupData |
布林值 |
|
否 |
MySQLBackup.spec.backupProfile
描述:如果未指定 backupProfileName,則為 backupProfile 規格
表 8.58 MySQLBackup.spec.backupProfile 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
dumpInstance |
物件 | 否 | |
podAnnotations |
物件 | 否 | |
podLabels |
物件 | 否 |
MySQLBackup.spec.backupProfile.dumpInstance
表 8.59 MySQLBackup.spec.backupProfile.dumpInstance 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
dumpOptions |
物件 | 直接傳遞至 MySQL Shell 的 DumpInstance() 的鍵值組字典 |
否 |
storage |
物件 | 否 |
MySQLBackup.spec.backupProfile.dumpInstance.storage
表 8.60 MySQLBackup.spec.backupProfile.dumpInstance.storage 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
azure |
物件 | 否 | |
ociObjectStorage |
物件 | 否 | |
persistentVolumeClaim |
物件 | 要使用的 PVC 規格。在執行備份的 Pod 中「按原樣」使用。 |
否 |
s3 |
物件 | 否 |
MySQLBackup.spec.backupProfile.dumpInstance.storage.azure
表 8.61 MySQLBackup.spec.backupProfile.dumpInstance.storage.azure 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
config |
字串 | 具有 Azure BLOB 儲存體設定和認證的 Secret 名稱 |
是 |
containerName |
字串 | 儲存 Dump 的 Azure BLOB 儲存體容器名稱 |
是 |
prefix |
字串 | 容器中儲存 Dump 檔案的路徑 |
否 |
MySQLBackup.spec.backupProfile.dumpInstance.storage.ociObjectStorage
表 8.62 MySQLBackup.spec.backupProfile.dumpInstance.storage.ociObjectStorage 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存備份的 OCI 儲存桶名稱 |
是 |
credentials |
字串 | 具有存取儲存桶資料的 Secret 名稱 |
是 |
prefix |
字串 | 儲存備份的儲存桶路徑 |
否 |
MySQLBackup.spec.backupProfile.dumpInstance.storage.s3
表 8.63 MySQLBackup.spec.backupProfile.dumpInstance.storage.s3 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucketName |
字串 | 儲存 Dump 的 S3 儲存桶名稱 |
是 |
config |
字串 | 具有 S3 設定和認證的 Secret 名稱 |
是 |
endpoint |
字串 | 覆寫端點 URL |
否 |
prefix |
字串 | 儲存 Dump 檔案的儲存桶路徑 |
否 |
profile |
字串 |
設定檔正在設定檔中使用的設定檔
|
否 |
MySQLBackup.status
表 8.64 MySQLBackup.status 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
bucket |
字串 | 否 | |
completionTime |
字串 | 否 | |
container |
字串 | 否 | |
elapsedTime |
字串 | 否 | |
message |
字串 | 否 | |
method |
字串 | 否 | |
ociTenancy |
字串 | 否 | |
output |
字串 | 否 | |
size |
字串 | 否 | |
source |
字串 | 否 | |
spaceAvailable |
字串 | 否 | |
startTime |
字串 | 否 | |
status |
字串 | 否 |
資源類型
ClusterKopfPeering
表 8.65 ClusterKopfPeering 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
apiVersion | 字串 | zalando.org/v1 | 是 |
kind | 字串 | ClusterKopfPeering | 是 |
metadata | 物件 | 請參閱 Kubernetes API 文件 | 是 |
status |
物件 | 否 |
KopfPeering
表 8.66 KopfPeering 的規格表
名稱 | 類型 | 描述 | 必要 |
---|---|---|---|
apiVersion | 字串 | zalando.org/v1 | 是 |
kind | 字串 | KopfPeering | 是 |
metadata | 物件 | 請參閱 Kubernetes API 文件 | 是 |
status |
物件 | 否 |