What is Kubernetes Operator?
Kubernetes operator is a custom controller that extends Kubernetes functionalities. Operator is responsible for managing pods, services, containers, volumes, and other system resources. Operator automates tasks and manages complex applications in Kubernetes.
Kubernetes operator uses custom resources (CR) to manage applications and their components. The Kubernetes operator translates the high-level directives provided by the users within a CR into the low-level actions, based on best practices embedded within the operator’s logic.
Introducing DxOperator
DxOperator is a Kubernetes operator that uses custom resource definitions to automate the deployment of DxEnterprise clusters. DxEnterprise then provides all the instrumentation to create, configure, manage, and provide automatic failover for Microsoft SQL Server availability group workloads in Kubernetes.
What can you do with DxOperator?
DxOperator gives you full control of how your SQL instances and availability groups are configured and function to support your production workloads. In collaboration with the Microsoft SQL Server team, we have committed the following list of features in this DxOperator version. To see how you can deploy Always on Availability Groups for SQL Server containers on Kubernetes – The DxOperator way, head over to @Amit’s blog.
Custom Pod name
Pod name is a part of the Kubernetes metadata used to identify the deployed pod(s).
Assigning pods to nodes
DxOperator supports node selection for pods as defined by Kubernetes guidance.
Assigning pods to nodes using node affinity
To schedule a pod based on the node affinity, apply the Kubernetes guidance in the CR.
SQL availability group name and cluster type
Define appropriate name for the SQL availability group that best fits your application or environment. Cluster type can also be specified. Valid values for cluster type are EXTERNAL (automatic failover) and NONE (no automatic failover).
SQL availability group replicas
Specify the desired synchronous, asynchronous, and/or configuration_only replicas for the deployment. Please note that configuration_only replica is only supported when the cluster type is EXTERNAL.
SQL availability group options
For SQL Server 2022, DxOperator provides additional options (with) to apply when creating SQL availability groups, including CONTAINED. You can refer to Microsoft documentation for the available options for your version of SQL Server deployment.
SQL availability group listener port
Specify the listener port for the SQL availability group.
Pod load balancer
As part of the deployment of the pod(s), an external load balancer may need to be created to allow external access to the pod(s) running inside Kubernetes. Specify if a load balancer is to be created.
Custom Pod annotations
Annotations are key-value pairs associated with the deployed resources, used to provide further information about the resources.
DxEnterprise container specification
Specify desired container image, image pull policy, EULA acceptance, Kubernetes secret, and whether to join an existing DxEnterprise cluster. If joining an existing cluster is desired, the DX_OTPK value must be present in the Kubernetes secret.
SQL Server container specification
Specify desired container image, image pull policy, EULA acceptance, product ID/edition, Kubernetes secret, and config map name.
User-defined volume class
Depending on workload, it may be necessary to assign dedicated storage for each of the containers. DxOperator supports user-defined volume class for each of the desired containers.
Quality of Service (QoS)
When deploying production grade applications in Kubernetes, it is important to set the desired QoS for each of the containers to ensure that the container performs within desired metrics. DxOperator supports QoS through the following parameters.
Additional side-car containers
DxOperator allows any additional container(s) to be deployed along with DxEnterprise and SQL Server as side-car container(s). An example of such a side-car container is mssql-tools.
ConfigMap
The ConfigMap object supports SQL Server specific mssql-conf settings to be defined. Any data defined here is copied into the mssql instance’s mssql.conf file.
Final word
DxOperator is a powerful toolset. With DxOperator, you can easily and quickly deploy any SQL availability group instances in Kubernetes, with any desired specifications and parameters of your choosing. To get started with DxOperator, head over to https://dh2i.com/dxoperator/, sign up for a DxEnterprise developer license, download the quick start guide, and take DxOperator for a spin.
If you’re interested in learning more about DH2i’s approach to smart high availability technology, get signed up for a one-on-one demo today.
Most Recent Posts:
- DH2i Receives 2024 Excellence Award from Cloud Computing Magazine
- Hurricane Season’s Still Here: Implementing Unified High Availability & Disaster Recovery For SQL Server Environments
- Beyond Bargains: Black Friday and Cyber Monday’s Cybersecurity Demands
- DH2i to Showcase at PASS Data Community Summit 2024
- How Educational Institutions Can Fortify Security Defenses