Skip to content

Commit

Permalink
docs: update schema
Browse files Browse the repository at this point in the history
Replace pvc/pv migration by animated gif.

Signed-off-by: Serge Logvinov <[email protected]>
  • Loading branch information
sergelogvinov committed Oct 30, 2024
1 parent 1102ba1 commit d90ffef
Show file tree
Hide file tree
Showing 4 changed files with 116 additions and 70 deletions.
78 changes: 8 additions & 70 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,80 +33,18 @@ It enables the use of a single storage class to deploy one or many deployments/s

## Overview

Proxmox cluster with local storage like: lvm, lvm-thin, zfs, xfs, ext4, etc.

![ProxmoxClusers!](/docs/proxmox-regions.jpeg)
![ProxmoxClusers!](/docs/proxmox-regions.gif)

Arrows with dotted lines indicate the capability of attaching a Persistent Volume (PV) to a Pod.

- Each Proxmox cluster has predefined in cloud-config the region name (see `clusters[].region` below).
- Each Proxmox Cluster has many Proxmox Nodes. In kubernetes scope it is called as `zone`. The name of `zone` is the name of Proxmox node.
- Each Proxmox cluster has many Proxmox Nodes. In kubernetes scope it is called as `zone`. The name of `zone` is the name of Proxmox node.
- Pods can easily migrate between Kubernetes nodes on the same physical Proxmox node (`zone`).
The PV will automatically be moved by the CSI Plugin.
- Pods with PVC `cannot` automatically migrate across zones (Proxmox nodes).
You can manually move PVs across zones using [pvecsictl](docs/pvecsictl.md) to migrate Pods across zones.


```mermaid
---
title: Automatic Pod migration within zone
---
flowchart LR
subgraph cluster1["Proxmox Cluster (Region 1)"]
subgraph node11["Proxmox Node (zone 1)"]
direction BT
subgraph vm1["VM (worker 1)"]
pod11(["Pod (pv-1)"])
end
subgraph vm2["VM (worker 2)"]
pod12(["Pod (pv-1)"])
end
pv11[("Disk (pv-1)")]
end
subgraph node12["Proxmox Node (zone 2)"]
direction BT
subgraph vm3["VM (worker 3)"]
pod22(["Pod (pv-2)"])
end
pv22[("Disk (pv-2)")]
end
end
pv11 .-> vm1
pv11 -->|automatic| vm2
pod11 -->|migrate| pod12
pv22 --> vm3
```
```mermaid
---
title: Manual migration using pvecsictl across zones
---
flowchart
subgraph cluster1["Proxmox Cluster (Region 1)"]
direction BT
subgraph node11["Proxmox Node (zone 1)"]
subgraph vm1["VM (worker 1)"]
pod11["Pod (pv-1)"]
end
subgraph vm2["VM (worker 2)"]
pod21["Pod (pv-2)"]
end
pv11[("Disk (pv-1)")]
pv21[("Disk (pv-2)")]
end
subgraph node12["Proxmox Node (zone 2)"]
direction TB
subgraph vm3["VM (worker 3)"]
pod22["Pod (pv-2)"]
end
pv22[("Disk (pv-2)")]
end
end
pv11 --> vm1
pv21 .-> vm2
pv22 --> vm3
pod21 -->|migrate| pod22
pv21 -->|pvecsictl| pv22
```
- Pods with Persistent Volume (PV) allocated on `local storage (like: lvm, lvm-thin, zfs, xfs, ext4)` **cannot** automatically migrate across zones (Proxmox nodes).
You can manually move PVs across zones using [pvecsictl](docs/pvecsictl.md) tool.
- Pods with Persistent Volume (PV) allocated on `shared disk (like: ceph, nfs)` **can** automatically migrate across regions (Proxmox cluster).

## Installation

Expand Down Expand Up @@ -280,7 +218,7 @@ Source:
storage=data
```

### Usage
## Disk usage capacity

Check existence of CSIDriver

Expand Down
76 changes: 76 additions & 0 deletions docs/architecture.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Architecture

Proxmox cluster with local storage like: lvm, lvm-thin, zfs, xfs, ext4, etc.

![ProxmoxClusers!](/docs/proxmox-regions.jpeg)

- Each Proxmox cluster has predefined in cloud-config the region name (see `clusters[].region` below).
- Each Proxmox Cluster has many Proxmox Nodes. In kubernetes scope it is called as `zone`. The name of `zone` is the name of Proxmox node.
- Pods can easily migrate between Kubernetes nodes on the same physical Proxmox node (`zone`).
The PV will automatically be moved by the CSI Plugin.
- Pods with PVC `cannot` automatically migrate across zones (Proxmox nodes).
You can manually move PVs across zones using [pvecsictl](docs/pvecsictl.md) to migrate Pods across zones.


```mermaid
---
title: Automatic Pod migration within zone
---
flowchart LR
subgraph cluster1["Proxmox Cluster (Region 1)"]
subgraph node11["Proxmox Node (zone 1)"]
direction BT
subgraph vm1["VM (worker 1)"]
pod11(["Pod (pv-1)"])
end
subgraph vm2["VM (worker 2)"]
pod12(["Pod (pv-1)"])
end
pv11[("Disk (pv-1)")]
end
subgraph node12["Proxmox Node (zone 2)"]
direction BT
subgraph vm3["VM (worker 3)"]
pod22(["Pod (pv-2)"])
end
pv22[("Disk (pv-2)")]
end
end
pv11 .-> vm1
pv11 -->|automatic| vm2
pod11 -->|migrate| pod12
pv22 --> vm3
```
```mermaid
---
title: Manual migration using pvecsictl across zones
---
flowchart
subgraph cluster1["Proxmox Cluster (Region 1)"]
direction BT
subgraph node11["Proxmox Node (zone 1)"]
subgraph vm1["VM (worker 1)"]
pod11["Pod (pv-1)"]
end
subgraph vm2["VM (worker 2)"]
pod21["Pod (pv-2)"]
end
pv11[("Disk (pv-1)")]
pv21[("Disk (pv-2)")]
end
subgraph node12["Proxmox Node (zone 2)"]
direction TB
subgraph vm3["VM (worker 3)"]
pod22["Pod (pv-2)"]
end
pv22[("Disk (pv-2)")]
end
end
pv11 --> vm1
pv21 .-> vm2
pv22 --> vm3
pod21 -->|migrate| pod22
pv21 -->|pvecsictl| pv22
```
32 changes: 32 additions & 0 deletions docs/eraser.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
direction down
styleMode: plain

CLUSTER1 [label: "Proxmox Cluster (Region-1)"] {
Node 1 [label: "Proxmox Node 1 (zone 1)"] {
VM1 [label: "VM-1"] {
pod2 [icon: k8s-pod, label: "pod", colorMode: outline, color: black] {
pvc1 [icon: k8s-pvc, label: "pvc", colorMode: outline, color: black]}
}
VM2 [label: "VM-2"] {
pod3 [icon: k8s-pod, label: "pod", colorMode: outline, color: black] {
pvc3 [icon: k8s-pvc, label: "pvc", colorMode: outline, color: black]}
}
DiskNode1 [icon:azure-disks, label:"Local Disk"]
}
Node 2 [label: "Proxmox Node 2 (zone 2)"] {
VM3 [label: "VM-3"] {
pod4 [icon: k8s-pod, label: "pod", colorMode: bold] {
pvc4 [icon: k8s-pvc, label: "pvc", colorMode: bold]
}
}
DiskNode2 [icon:azure-disks, label:"Local Disk"]
}
DiskSH1 [icon:azure-disk-pool, label:"Shared Disk"]
}

pvc1 -- DiskNode1
pvc3 -- DiskNode1
pvc4 -- DiskNode2
pvc1 -- DiskSH1
pvc3 -- DiskSH1
pvc4 - DiskSH1
Binary file added docs/proxmox-regions.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit d90ffef

Please sign in to comment.