eck:Elasticsearch running in k8s use Kubernetes operator

https://www.elastic.co/guide/en/cloud-on-k8s/2.1/index.html

 

The value set for cpu requests directly impacts Elasticsearch node.processors setting. For example, with resources.requests.cpu: 1,

Elasticsearch effectively relies on a single core

 

Table 1. Default limits applied by the operator

TypeRequestsLimits

APM Server

512Mi

512Mi

Elasticsearch

2Gi

2Gi

Kibana

1Gi

1Gi

Beat

200Mi

200Mi

Elastic Agent

350Mi

350Mi

Elastic Maps Sever

200Mi

200Mi

Enterprise Search

4Gi

4Gi

 

安装:

三步,装crd,装operator,查看log

  1. Install custom resource definitions:

    kubectl create -f https://download.elastic.co/downloads/eck/2.1.0/crds.yaml

    The following Elastic resources have been created:

    customresourcedefinition.apiextensions.k8s.io/agents.agent.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/apmservers.apm.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/beats.beat.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/elasticmapsservers.maps.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/elasticsearches.elasticsearch.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/enterprisesearches.enterprisesearch.k8s.elastic.co created
    customresourcedefinition.apiextensions.k8s.io/kibanas.kibana.k8s.elastic.co created
  2. Install the operator with its RBAC rules:

    kubectl apply -f https://download.elastic.co/downloads/eck/2.1.0/operator.yaml
     

    The ECK operator runs by default in the elastic-system namespace. It is recommended that you choose a dedicated namespace for your workloads, rather than using the elastic-system or the default namespace.

  3. Monitor the operator logs:

    kubectl -n elastic-system logs -f statefulset.apps/elastic-operator

When you run the kubectl command listed in Deploy ECK in your Kubernetes cluster, the following components are installed or updated:

  • CustomResourceDefinition objects for all supported resource types (Elasticsearch, Kibana, APM Server, Enterprise Search, Beats, Elastic Agent, and Elastic Maps Server).
  • Namespace named elastic-system to hold all operator resources.
  • ServiceAccountClusterRole and ClusterRoleBinding to allow the operator to manage resources throughout the cluster.
  • ValidatingWebhookConfiguration to validate Elastic custom resources on admission.
  • StatefulSetConfigMapSecret and Service in elastic-system namespace to run the operator application.
posted @ 2022-03-18 20:27  mmgithub123  阅读(73)  评论(0编辑  收藏  举报