Skip to content

NimTechnology

Trình bày các công nghệ CLOUD một cách dễ hiểu.

  • Kubernetes & Container
    • Docker
    • Kubernetes
      • Ingress
    • Helm Chart
    • Isito-EnvoyFilter
    • Apache Kafka
      • Kafka
      • Kafka Connect
      • Lenses
    • Vault
    • Longhorn – Storage
    • VictoriaMetrics
    • MetalLB
    • Kong Gateway
  • CI/CD
    • ArgoCD
    • ArgoWorkflows
    • Spinnaker
    • Jenkins
    • Harbor
    • TeamCity
    • Git
      • Bitbucket
  • Coding
    • Terraform
      • GCP – Google Cloud
      • AWS – Amazon Web Service
    • Golang
    • Laravel
    • Python
    • Jquery & JavaScript
    • Selenium
  • Log & Monitor
    • DataDog
    • Prometheus
    • Grafana
    • ELK
      • Kibana
      • Logstash
  • BareMetal
    • NextCloud
  • Toggle search form

[Longhorn/Storage] Install Longhorn on Kubernetes through helm and config Taints and Tolerations

Posted on August 24, 2021November 9, 2021 By nim No Comments on [Longhorn/Storage] Install Longhorn on Kubernetes through helm and config Taints and Tolerations

Contents

  • 1) Intall Longhorn by helm
  • 2) Overview and material references
  • 3) Practice – update Sat 23 Oct 2021

1) Intall Longhorn by helm

https://longhorn.io/docs/1.1.2/deploy/install/install-with-helm/

helm repo add longhorn https://charts.longhorn.io
kubectl create namespace longhorn-system
helm install longhorn longhorn/longhorn --namespace longhorn-system

Nếu bạn có cluster có nhưng node chạy SSD và bạn muốn longhorn được deploy trên đó thì làm theo mình

Taints and Tolerations Usage with Node Selector in Kubernetes Scheduling
kubectl label nodes k8s-worker-storage1 node=storage-ssd
kubectl taint node k8s-worker-storage1 node=storage-ssd:NoSchedule

Tham khảo bài viết trên để hiều tains and tolerations node

sử value này cho helm

longhornManager:
  tolerations:
    - key: "node"
      operator: "Equal"
      value: "storage-ssd"
      effect: "NoSchedule"
  nodeSelector:
    node: "storage-ssd"

longhornDriver:
  tolerations:
    - key: "node"
      operator: "Equal"
      value: "storage-ssd"
      effect: "NoSchedule"
  nodeSelector:
    node: "storage-ssd"

longhornUI:
  tolerations:
    - key: "node"
      operator: "Equal"
      value: "storage-ssd"
      effect: "NoSchedule"
  nodeSelector:
    node: "storage-ssd"

2) Overview and material references

sau khi deploy xong thì kiểm tra

Ok đã đúng node mong muốn

Tiện mà mình rút ra:

  • Quản lý, tạo, xoá PV và PVC rất tiện và dễ thực hiện.
  • Dynamically provision persistent volumes in Kubernetes: rất tiện cho anh/em khi cài app thông qua helm, không phải suy nghĩ nên tạo pvc và pv như thế nào.

Có video hướng dẫn luôn nhé! mọi người coi để thấy cách control longhorn như thế nào

3) Practice – update Sat 23 Oct 2021

Như trước thì mình sẽ cần tạo pv, rồi tạo pvc
Giờ nhẹ nhàng hơn bạn chỉ apply pvc với storageClass là longhorn

---
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  labels:
    name: jenkins-permanent
  name: jenkins-permanent
spec:
  storageClassName: longhorn
  accessModes:
    - "ReadWriteOnce"
  resources:
    requests:
      storage: "8Gi"

4) Upgrade longhorn

Kubernetes & Container, Longhorn - Storage

Post navigation

Previous Post: [Keycloak/OAuth2] Install Keycloak by helm on Kubernetes
Next Post: [issue/alpine] docker 20.10.2 -> golang:1-alpine3.14 error: make: go: Operation not permitted

More Related Articles

[Datree] Admission Controllers Or CLI? Kubernetes Policy Validations with Datree Kubernetes & Container
[issue/alpine] docker 20.10.2 -> golang:1-alpine3.14 error: make: go: Operation not permitted Docker
[Chartmuseum] Build yourself a Helm Chart Repository server Kubernetes & Container
[Jenkins – Kubernestes] Jenkins tạo Jenkins slave trên Kubernetes CI/CD
[Kubernestes] I waiting too long but my workload is still unavailable Kubernetes & Container
[Kubernetes] Gateway API – Ingress And Service Mesh Spec Replacement? Kubernetes & Container

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Tham Gia Group DevOps nhé!
Để Nim có nhiều động lực ra nhiều bài viết.
Để nhận được những thông báo mới nhất.

Recent Posts

  • Experiences for IP Addresses Shortage on EKS Clusters March 29, 2023
  • [Talisman] Discover the sensitive information in your code. March 28, 2023
  • [Prometheus/Grafana] Install Prometheus and Grafana on ubuntu. March 27, 2023
  • [Kong Gateway] WebSocket connection failed March 26, 2023
  • [Nextcloud] Can’t download files to have a size bigger than 2Gi on NextCloud – RaspBerry March 24, 2023

Archives

  • March 2023
  • February 2023
  • January 2023
  • December 2022
  • November 2022
  • October 2022
  • September 2022
  • August 2022
  • July 2022
  • June 2022
  • May 2022
  • April 2022
  • March 2022
  • February 2022
  • January 2022
  • December 2021
  • November 2021
  • October 2021
  • September 2021
  • August 2021
  • July 2021
  • June 2021

Categories

  • BareMetal
    • NextCloud
  • CI/CD
    • ArgoCD
    • ArgoWorkflows
    • Git
      • Bitbucket
    • Harbor
    • Jenkins
    • Spinnaker
    • TeamCity
  • Coding
    • Golang
    • Jquery & JavaScript
    • Laravel
    • Python
    • Selenium
    • Terraform
      • AWS – Amazon Web Service
      • GCP – Google Cloud
  • Kubernetes & Container
    • Apache Kafka
      • Kafka
      • Kafka Connect
      • Lenses
    • Docker
    • Helm Chart
    • Isito-EnvoyFilter
    • Kong Gateway
    • Kubernetes
      • Ingress
    • Longhorn – Storage
    • MetalLB
    • Vault
    • VictoriaMetrics
  • Log & Monitor
    • DataDog
    • ELK
      • Kibana
      • Logstash
    • Grafana
    • Prometheus
  • Uncategorized
  • Admin

Copyright © 2023 NimTechnology.