ホットスタンバイ構成の継続的リカバリ方式およびストリーミングレプリケーション方式の配備手順を説明します。
本番環境のFEPClusterのカスタムリソース定義には、ホットスタンバイ構成のみで使用するパラメタなどは存在しません。継続的リカバリ方式を利用する場合には、災害対策環境でのFEPClusterのカスタムリソースを下記のように定義します。
apiVersion: fep.fujitsu.io/v2
kind: FEPCluster
metadata:
…
spec:
fep:
standby:
enable: true
method: archive-recovery
pgBackrestConf: |
[global]
log-path=/database/log/backup
repo1-type=azure
repo1-path=< Backup path of primary/ cluster from which data is to be restored>
repo1-azure-account=<my storage account>
repo1-azure-container=fepbackups
repo1-azure-key=<my storage account key >
…ストリーミングレプリケーション方式を利用する場合は、下記のように定義します。
apiVersion: fep.fujitsu.io/v2
kind: FEPCluster
metadata:
...
spec:
fep:
standby:
enable: true
method: streaming
streaming:
host: <LoadBalancer IP>
port: 27500
pgBackrestConf: |
[global]
log-path=/database/log/backup
repo1-type=azure
repo1-path=< Backup path of primary/ cluster from which data is to be restored>
repo1-azure-account=<my storage account>
repo1-azure-container=fepbackups
repo1-azure-key=<my storage account key >
...ストリーミングレプリケーションでは、FEPClusterCRを上記のように定義しますが、別途LoadBalancerを配備する必要があります。
kind: Service
apiVersion: v1
metadata:
name: my-fep-internal-svc
namespace: sample-namespace
annotations:
service.beta.kubernetes.io/azure-load-balancer-internal: 'true'
spec:
ports:
- protocol: TCP
port: 27500
type: LoadBalancer
selector:
app: <my-fep-cluster>-sts
feprole: master