From 1990d5a01190e518566be9e9317c4b0b18f769c5 Mon Sep 17 00:00:00 2001 From: Timmy Date: Fri, 10 Apr 2026 11:12:15 +0800 Subject: [PATCH] docs: add README, API reference, quickstart guide, and cluster summary - README.md: project landing page with cluster overview and doc index - API.md: comprehensive Proxmox VE API endpoint reference - QUICKSTART.md: 5-minute guide with copy-paste examples - SUMMARY.md: cluster health, resource usage, and service inventory - CLAUDE.md: Claude Code project context Co-Authored-By: Claude Opus 4.6 (1M context) --- API.md | 229 ++++++++++++++++++++++++++++++++++++++++++++++++++ CLAUDE.md | 34 ++++++++ QUICKSTART.md | 159 +++++++++++++++++++++++++++++++++++ README.md | 51 +++++++++++ SUMMARY.md | 130 ++++++++++++++++++++++++++++ 5 files changed, 603 insertions(+) create mode 100644 API.md create mode 100644 CLAUDE.md create mode 100644 QUICKSTART.md create mode 100644 README.md create mode 100644 SUMMARY.md diff --git a/API.md b/API.md new file mode 100644 index 0000000..00273d7 --- /dev/null +++ b/API.md @@ -0,0 +1,229 @@ +# Proxmox VE API 參考手冊 + +> 適用版本:PVE 8.4.14 | 基底 URL:`https://192.168.42.38:8006/api2/json/` + +## 認證 + +### API Token(推薦) + +```bash +# 在 Header 中帶入 Token +curl -sk https://192.168.42.38:8006/api2/json/<端點> \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" +``` + +Token 格式:`PVEAPIToken=<使用者>!=` + +### 現有 Token + +| Token ID | privsep | 權限 | 狀態 | +|---|---|---|---| +| `root@pam!claude` | 0(繼承 root) | 完整權限 | 可用 | +| `root@pam!automation` | 1(獨立權限) | PVEAdmin 角色 | secret 已遺失 | + +### Ticket 認證(帳密登入,2 小時過期) + +```bash +# 步驟 1:取得 ticket + CSRF token +RESPONSE=$(curl -sk https://192.168.42.38:8006/api2/json/access/ticket \ + -d "username=root@pam&password=<密碼>") + +TICKET=$(echo $RESPONSE | python3 -c "import sys,json; print(json.load(sys.stdin)['data']['ticket'])") +CSRF=$(echo $RESPONSE | python3 -c "import sys,json; print(json.load(sys.stdin)['data']['CSRFPreventionToken'])") + +# 步驟 2:GET 請求 +curl -sk https://192.168.42.38:8006/api2/json/<端點> \ + -b "PVEAuthCookie=$TICKET" + +# 步驟 3:POST/PUT/DELETE 請求(需額外帶 CSRF) +curl -sk -X POST https://192.168.42.38:8006/api2/json/<端點> \ + -b "PVEAuthCookie=$TICKET" \ + -H "CSRFPreventionToken: $CSRF" \ + -d "參數=值" +``` + +## Token 管理 + +```bash +# 建立 token(SSH 到 PVE 執行,secret 只顯示一次) +pvesh create /access/users/root@pam/token/<名稱> --privsep 0 --expire 0 + +# 列出 token +pvesh get /access/users/root@pam/token --output-format json + +# 刪除 token +pvesh delete /access/users/root@pam/token/<名稱> + +# 透過 API 建立 +curl -sk -X POST https://192.168.42.38:8006/api2/json/access/users/root@pam/token/<名稱> \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" \ + -d "privsep=0&expire=0" +``` + +## 端點參考 + +以下所有端點前綴為 `https://192.168.42.38:8006/api2/json`。 + +### 叢集 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/version` | API 版本 | +| GET | `/cluster/status` | 叢集狀態與 quorum | +| GET | `/cluster/resources` | 所有資源總覽 | +| GET | `/cluster/resources?type=vm` | 僅 VM/容器 | +| GET | `/cluster/resources?type=storage` | 僅儲存 | +| GET | `/cluster/resources?type=node` | 僅節點 | + +### 節點 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/nodes` | 節點清單 | +| GET | `/nodes/{node}/status` | 節點詳細狀態 | +| GET | `/nodes/{node}/network` | 網路介面設定 | +| GET | `/nodes/{node}/storage` | 儲存清單 | +| GET | `/nodes/{node}/tasks` | 最近任務 | +| GET | `/nodes/{node}/tasks/{upid}/status` | 任務狀態 | + +> `{node}` 可用值:`pve`、`pve-02`、`pve-03` + +### QEMU 虛擬機 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/nodes/{node}/qemu` | 列出該節點所有 VM | +| GET | `/nodes/{node}/qemu/{vmid}/status/current` | VM 當前狀態 | +| GET | `/nodes/{node}/qemu/{vmid}/config` | VM 設定 | +| PUT | `/nodes/{node}/qemu/{vmid}/config` | 修改 VM 設定 | +| POST | `/nodes/{node}/qemu/{vmid}/status/start` | 啟動 VM | +| POST | `/nodes/{node}/qemu/{vmid}/status/stop` | 強制關閉 VM | +| POST | `/nodes/{node}/qemu/{vmid}/status/shutdown` | 優雅關機 | +| POST | `/nodes/{node}/qemu/{vmid}/status/reboot` | 重啟 VM | +| POST | `/nodes/{node}/qemu/{vmid}/status/reset` | 硬重置 VM | +| POST | `/nodes/{node}/qemu/{vmid}/clone` | 複製 VM | +| POST | `/nodes/{node}/qemu/{vmid}/snapshot` | 建立快照 | +| GET | `/nodes/{node}/qemu/{vmid}/snapshot` | 列出快照 | +| DELETE | `/nodes/{node}/qemu/{vmid}` | 刪除 VM | + +### LXC 容器 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/nodes/{node}/lxc` | 列出該節點所有容器 | +| GET | `/nodes/{node}/lxc/{vmid}/status/current` | 容器當前狀態 | +| GET | `/nodes/{node}/lxc/{vmid}/config` | 容器設定 | +| PUT | `/nodes/{node}/lxc/{vmid}/config` | 修改容器設定 | +| POST | `/nodes/{node}/lxc/{vmid}/status/start` | 啟動容器 | +| POST | `/nodes/{node}/lxc/{vmid}/status/stop` | 停止容器 | +| POST | `/nodes/{node}/lxc/{vmid}/status/shutdown` | 優雅關閉 | +| POST | `/nodes/{node}/lxc/{vmid}/status/reboot` | 重啟容器 | +| POST | `/nodes/{node}/lxc/{vmid}/clone` | 複製容器 | +| POST | `/nodes/{node}/lxc/{vmid}/snapshot` | 建立快照 | +| GET | `/nodes/{node}/lxc/{vmid}/snapshot` | 列出快照 | +| DELETE | `/nodes/{node}/lxc/{vmid}` | 刪除容器 | + +### 儲存 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/nodes/{node}/storage` | 列出儲存 | +| GET | `/nodes/{node}/storage/{storage}/status` | 儲存狀態 | +| GET | `/nodes/{node}/storage/{storage}/content` | 儲存內容(ISO/備份/磁碟) | +| POST | `/nodes/{node}/storage/{storage}/upload` | 上傳 ISO/模板 | +| DELETE | `/nodes/{node}/storage/{storage}/content/{volume}` | 刪除內容 | + +> `{storage}` 可用值:`local`、`local-lvm`、`syno-lvm`、`synology-backup`、`pbs` + +### 備份 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/cluster/backup` | 列出備份排程 | +| POST | `/cluster/backup` | 建立備份排程 | +| GET | `/cluster/backup/{id}` | 取得排程詳情 | +| PUT | `/cluster/backup/{id}` | 修改排程 | +| DELETE | `/cluster/backup/{id}` | 刪除排程 | +| POST | `/nodes/{node}/vzdump` | 立即執行備份 | + +### 使用者與權限 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/access/users` | 列出使用者 | +| POST | `/access/users` | 建立使用者 | +| GET | `/access/roles` | 列出角色 | +| GET | `/access/acl` | 列出 ACL | +| PUT | `/access/acl` | 修改 ACL | + +### 防火牆 + +| 方法 | 端點 | 說明 | +|---|---|---| +| GET | `/nodes/{node}/firewall/rules` | 節點防火牆規則 | +| GET | `/nodes/{node}/qemu/{vmid}/firewall/rules` | VM 防火牆規則 | +| GET | `/nodes/{node}/lxc/{vmid}/firewall/rules` | CT 防火牆規則 | +| GET | `/cluster/firewall/groups` | 防火牆安全群組 | + +## 回傳格式 + +所有回傳皆為 JSON,結構統一: + +```json +{ + "data": <回傳資料(物件或陣列)> +} +``` + +錯誤時: + +```json +{ + "errors": { "<欄位>": "<錯誤訊息>" }, + "data": null +} +``` + +HTTP 狀態碼: +- `200` 成功 +- `400` 參數錯誤 +- `401` 未認證 +- `403` 無權限 +- `500` 伺服器錯誤 + +## 非同步任務 + +修改類操作(啟動、關閉、備份、複製等)會回傳 UPID(任務 ID),可用來追蹤進度: + +```bash +# 回傳範例 +{"data": "UPID:pve:000F4D1C:01234567:12345678:qmstart:110:root@pam!claude:"} + +# 查詢任務狀態 +curl -sk https://192.168.42.38:8006/api2/json/nodes/pve/tasks//status \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" + +# 查詢任務日誌 +curl -sk https://192.168.42.38:8006/api2/json/nodes/pve/tasks//log \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" +``` + +## pvesh CLI 對照 + +API 端點可直接用 `pvesh` 在 PVE 節點上執行,無需認證: + +```bash +# GET /cluster/resources +ssh 192.168.42.38 "pvesh get /cluster/resources --output-format json" + +# POST /nodes/pve/lxc/102/status/start +ssh 192.168.42.38 "pvesh create /nodes/pve/lxc/102/status/start" + +# PUT /nodes/pve/lxc/102/config +ssh 192.168.42.38 "pvesh set /nodes/pve/lxc/102/config --memory 1024" + +# DELETE /nodes/pve/lxc/999 +ssh 192.168.42.38 "pvesh delete /nodes/pve/lxc/999" +``` + +pvesh 方法對照:`GET → get`、`POST → create`、`PUT → set`、`DELETE → delete` diff --git a/CLAUDE.md b/CLAUDE.md new file mode 100644 index 0000000..56255b3 --- /dev/null +++ b/CLAUDE.md @@ -0,0 +1,34 @@ +# CLAUDE.md + +This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. + +## Project Overview + +This repository documents and manages a 3-node Proxmox VE cluster ("PVECluster") running at 192.168.42.38/39/40. It contains infrastructure documentation and will serve as the base for automation scripts and tooling. + +## Proxmox VE API Access + +All API calls go through `https://192.168.42.38:8006/api2/json/`. Authenticate with: + +``` +Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879 +``` + +SSH is available to all three nodes (42.38, 42.39, 42.40) without password from the development machine. Use `pvesh` over SSH for CLI-based management. + +## Cluster Topology + +- **3 identical nodes**: Intel i3-6100 (2C/4T), 16GB RAM each +- **Primary storage**: Synology NAS at 192.168.42.20 via iSCSI (`syno-lvm`, 1TB shared LVM) +- **Backup storage**: Synology CIFS (`synology-backup`, 2.75TB) + Proxmox Backup Server (VM 111 at 192.168.42.30) +- **Networking**: All VMs/CTs on `vmbr0`, static IPs matching VMID pattern `192.168.42.` +- **Gateway**: 192.168.42.10 (OpenWRT VM 110 handles routing/firewall) + +## Key Files + +- `PVE_API.md` — API authentication methods, endpoint reference, token management +- `PVECluster_Architecture.md` — Full cluster architecture: nodes, VMs/CTs, storage, networking, backup strategy + +## Language + +Always respond in Traditional Chinese (繁體中文,台灣用語). diff --git a/QUICKSTART.md b/QUICKSTART.md new file mode 100644 index 0000000..bf9fa00 --- /dev/null +++ b/QUICKSTART.md @@ -0,0 +1,159 @@ +# 快速上手指南 + +5 分鐘內開始操作 PVECluster。 + +## 前置條件 + +- 可連線至 `192.168.42.0/24` 網段 +- 已安裝 `curl` 和 `python3`(用於解析 JSON) + +## 1. 確認連線 + +```bash +# SSH(三台任一皆可) +ssh 192.168.42.38 "pveversion" +# 預期輸出:pve-manager/8.4.14/... + +# API +curl -sk https://192.168.42.38:8006/api2/json/version \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" +# 預期輸出:{"data":{"version":"8.4.14",...}} +``` + +## 2. 設定環境變數(方便後續操作) + +```bash +export PVE_HOST="https://192.168.42.38:8006/api2/json" +export PVE_AUTH="Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" + +# 定義快捷函式 +pve-get() { curl -sk "$PVE_HOST$1" -H "$PVE_AUTH"; } +pve-post() { curl -sk -X POST "$PVE_HOST$1" -H "$PVE_AUTH" "${@:2}"; } +``` + +## 3. 查看叢集狀態 + +```bash +# 節點概覽 +pve-get /nodes | python3 -m json.tool + +# 所有 VM/容器 +pve-get /cluster/resources?type=vm | python3 -c " +import sys, json +data = json.load(sys.stdin)['data'] +data.sort(key=lambda x: x['vmid']) +print(f\"{'VMID':<6} {'Type':<5} {'Status':<9} {'Node':<8} {'Name':<12} {'CPU':>4} {'Mem':>8}\") +print('-' * 60) +for d in data: + mem = f\"{d['mem'] // 1048576}M\" if d['mem'] else '-' + print(f\"{d['vmid']:<6} {d['type']:<5} {d['status']:<9} {d['node']:<8} {d['name']:<12} {d.get('maxcpu','?'):>4} {mem:>8}\") +" +``` + +## 4. 常用操作範例 + +### 啟動 / 停止容器 + +```bash +# 啟動 CT103(N8N) +pve-post /nodes/pve/lxc/103/status/start + +# 優雅關閉 CT103 +pve-post /nodes/pve/lxc/103/status/shutdown + +# 強制停止 +pve-post /nodes/pve/lxc/103/status/stop +``` + +### 啟動 / 停止 VM + +```bash +# 啟動 VM 120(K3s Worker) +pve-post /nodes/pve-02/qemu/120/status/start + +# 關閉 VM +pve-post /nodes/pve-02/qemu/120/status/shutdown +``` + +### 查看單一 VM/容器狀態 + +```bash +# CT 狀態 +pve-get /nodes/pve/lxc/102/status/current | python3 -m json.tool + +# VM 狀態 +pve-get /nodes/pve/qemu/110/status/current | python3 -m json.tool +``` + +### 查看 / 修改設定 + +```bash +# 查看 CT102 設定 +pve-get /nodes/pve/lxc/102/config | python3 -m json.tool + +# 透過 SSH 修改記憶體(改為 1GB) +ssh 192.168.42.38 "pvesh set /nodes/pve/lxc/102/config --memory 1024" +``` + +### 儲存使用狀況 + +```bash +pve-get /cluster/resources?type=storage | python3 -c " +import sys, json +data = json.load(sys.stdin)['data'] +seen = set() +print(f\"{'Storage':<20} {'Type':<8} {'Shared':<7} {'Used':>10} {'Total':>10} {'Usage':>6}\") +print('-' * 65) +for d in sorted(data, key=lambda x: x['storage']): + key = d['storage'] + if key in seen: continue + seen.add(key) + total = d.get('maxdisk', 0) + used = d.get('disk', 0) + pct = f\"{used/total*100:.0f}%\" if total else '-' + print(f\"{key:<20} {d['plugintype']:<8} {'yes' if d.get('shared') else 'no':<7} {used//1073741824:>8} GB {total//1073741824:>8} GB {pct:>6}\") +" +``` + +### 立即備份 + +```bash +# 備份 CT115 到 PBS +pve-post /nodes/pve-02/vzdump \ + -d "vmid=115" \ + -d "storage=pbs" \ + -d "mode=snapshot" \ + -d "notes-template={{guestname}}" +``` + +### 建立快照 + +```bash +# CT 快照 +pve-post /nodes/pve/lxc/102/snapshot \ + -d "snapname=before-upgrade" \ + -d "description=升級前快照" + +# 列出快照 +pve-get /nodes/pve/lxc/102/snapshot | python3 -m json.tool +``` + +## 5. 節點與 VMID 對照速查 + +操作 API 需要知道目標在哪個節點上: + +| VMID | 節點 | 類型 | 用途 | +|---|---|---|---| +| 100-101, 107, 109, 115, 117 | pve-02 | lxc | SSH Jump, Headscale, MailPit, PDF, Lydia | +| 102-106, 113, 116, 119, 123, 126 | pve | lxc | Tailscale, N8N, Caddy, MyIP, Bark, Gotify | +| 108, 112, 114, 118, 124 | pve-03 | lxc | Python, OpenClaw, Podman, PG, NPM+Keycloak | +| 110, 121 | pve | qemu | OpenWRT, K3s | +| 111, 120 | pve-02 | qemu | PBS, K3s | +| 122 | pve-03 | qemu | K3s | + +> 不確定在哪個節點?用 `/cluster/resources?type=vm` 查詢即可。 + +## 6. Web UI + +瀏覽器開啟 `https://192.168.42.38:8006`,使用 `root` / PAM 認證登入。 +三個節點任一 IP 皆可進入同一管理介面。 diff --git a/README.md b/README.md new file mode 100644 index 0000000..32790da --- /dev/null +++ b/README.md @@ -0,0 +1,51 @@ +# 42_38 — PVECluster 基礎建設文件庫 + +管理與記錄 PVECluster(3 節點 Proxmox VE 叢集)的架構、API 操作指南及相關自動化工具。 + +## 叢集簡介 + +| 項目 | 值 | +|---|---| +| 叢集名稱 | PVECluster | +| PVE 版本 | 8.4.14 | +| 節點 | pve (192.168.42.38)、pve-02 (.39)、pve-03 (.40) | +| 硬體 | Intel i3-6100 / 16GB RAM x3 | +| VM/容器 | 27(20 running / 6 stopped / 1 template) | +| 主要儲存 | Synology NAS iSCSI 1TB + CIFS 2.75TB | +| 備份 | Proxmox Backup Server (VM 111) | + +## 文件索引 + +| 文件 | 說明 | +|---|---| +| [QUICKSTART.md](QUICKSTART.md) | 快速上手:連線、API 呼叫、常用操作 | +| [API.md](API.md) | Proxmox VE API 完整參考手冊 | +| [PVECluster_Architecture.md](PVECluster_Architecture.md) | 叢集架構詳細文件(硬體/網路/儲存/VM 清單) | +| [SUMMARY.md](SUMMARY.md) | 叢集狀態摘要與服務一覽 | + +## 網路拓撲 + +``` +Internet ─── [192.168.42.10 GW / OpenWRT] ─── vmbr0 (192.168.42.0/24) + │ + ┌─────────────────────────────┼─────────────────────────────┐ + │ │ │ + pve (.38) pve-02 (.39) pve-03 (.40) + VM110,121 + CT x12 VM111,120 + CT x6 VM122 + CT x5 +``` + +## 快速存取 + +```bash +# SSH 連線 +ssh 192.168.42.38 # pve +ssh 192.168.42.39 # pve-02 +ssh 192.168.42.40 # pve-03 + +# Web UI +https://192.168.42.38:8006 + +# API 呼叫 +curl -sk https://192.168.42.38:8006/api2/json/cluster/resources \ + -H "Authorization: PVEAPIToken=root@pam!claude=fefcffca-df6e-48de-8adf-7907cd2ea879" +``` diff --git a/SUMMARY.md b/SUMMARY.md new file mode 100644 index 0000000..091f975 --- /dev/null +++ b/SUMMARY.md @@ -0,0 +1,130 @@ +# PVECluster 狀態摘要 + +> 快照日期:2026-04-10 + +## 叢集健康狀態 + +| 指標 | 狀態 | +|---|---| +| 叢集 Quorum | 正常(3/3 節點在線) | +| HA | 未啟用 | +| 備份排程 | 全部停用(3 個排程 enabled=0) | +| 儲存 | 全部可用 | + +## 節點資源 + +| 節點 | CPU | 記憶體 | 系統碟 | Running | +|---|---|---|---|---| +| pve (.38) | 7% (4C) | 6.7 / 16 GB (43%) | 12.2 / 68 GB | 9 | +| pve-02 (.39) | 12% (4C) | 10.9 / 16 GB (70%) | 12.1 / 68 GB | 7 | +| pve-03 (.40) | 15% (4C) | 10.1 / 16 GB (64%) | 11.0 / 68 GB | 6 | +| **合計** | **12C (4C x3)** | **27.7 / 48 GB (58%)** | **35.3 / 204 GB** | **22** | + +## 儲存使用 + +| 儲存 | 類型 | 容量 | 已用 | 使用率 | +|---|---|---|---|---| +| syno-lvm | iSCSI LVM(共享) | 1.00 TB | 0.90 TB | 90% | +| synology-backup | CIFS(共享) | 2.75 TB | 2.37 TB | 86% | +| pbs | PBS(共享) | 294 GB | 16 GB | 5% | +| local-lvm (pve) | LVM thin | 157 GB | 3.7 GB | 2% | +| local-lvm (pve-02) | LVM thin | 160 GB | — | — | +| local-lvm (pve-03) | LVM thin | 160 GB | 12.8 GB | 8% | + +> **注意**:syno-lvm 使用率 90%,synology-backup 使用率 86%,需關注空間。 + +## 服務分類總覽 + +### 基礎設施 + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| OpenWRT 路由器 | VM 110 | .42.10 (GW) | pve | running | +| Caddy 反向代理 | CT 104 | .42.104 | pve | running | +| Nginx Proxy Manager | CT 124 | .42.124 | pve-03 | running | +| Proxmox Backup Server | VM 111 | .42.30 | pve-02 | running | + +### 遠端存取 / VPN + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| SSH Jump + Bore Tunnel | CT 100 | .42.100 | pve-02 | running | +| Headscale + RustDesk | CT 101 | .42.101 | pve-02 | running | +| Tailscale | CT 102 | .42.102 | pve | running | +| Headscale | CT 126 | .42.126 | pve | running | + +### 認證 + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| Keycloak SSO | CT 124 | .42.124 | pve-03 | running | + +### 應用程式 + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| Lydia (Production) | CT 115 | .42.115 | pve-02 | running | +| Lydia (Test) | CT 117 | .42.117 | pve-02 | running | +| OpenClaw | CT 112 | .42.112 | pve-03 | running | +| Karakeep 書籤管理 | CT 124 | .42.124 | pve-03 | running | + +### Kubernetes (K3s) + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| K3s Worker | VM 120 | — | pve-02 | running | +| K3s Worker | VM 121 | — | pve | running | +| K3s Worker | VM 122 | — | pve-03 | running | + +> 3 節點各 1 個 K3s Worker VM(8GB RAM / 82-83GB 磁碟),跨節點分佈。 + +### 開發 / 工具 + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| Python 開發環境 | CT 108 | .42.108 | pve-03 | running | +| PostgreSQL | CT 118 | .42.118 | pve-03 | running | +| Podman | CT 114 | .42.114 | pve-03 | running | + +### 通知 / 郵件 + +| 服務 | VMID | IP | 節點 | 狀態 | +|---|---|---|---|---| +| Bark 推播 | CT 116 | .42.116 | pve | running | +| MailPit 郵件測試 | CT 107 | .42.107 | pve-02 | running | +| MyIP Server | CT 105 | .42.105 | pve | running | +| Gotify 推播 | CT 119 | .42.119 | pve | **stopped** | + +### 已停用服務 + +| 服務 | VMID | IP | 節點 | 備註 | +|---|---|---|---|---| +| N8N 自動化 | CT 103 | .42.103 | pve | 曾用 Docker 跑 N8N | +| Podman(閒置) | CT 106 | .42.106 | pve | 空容器 | +| Stirling PDF | CT 109 | .42.109 | pve-02 | PDF 處理工具 | +| (閒置) | CT 113 | — | pve | 空容器,DHCP | +| Gotify 推播 | CT 119 | .42.119 | pve | 已被 Bark 取代 | +| (閒置) | CT 123 | .42.123 | pve | 空容器 | + +### 模板 + +| 名稱 | VMID | 節點 | +|---|---|---| +| Ubuntu 24.04 Cloud-init | VM 9000 | pve | + +## 備份排程狀態 + +全部排程目前皆為**停用狀態**(enabled=0): + +| 排程 | 對象 | 儲存 | 保留策略 | +|---|---|---|---| +| 每日 03:00 | CT115, CT117(Lydia) | pbs | keep-daily=7 | +| 02:30, 22:30 | CT103, CT106, CT108, CT124 | pbs | keep-daily=7 | +| 每日 02:00 | VM110(OpenWRT) | pbs | keep-daily=3 | + +## 需注意事項 + +1. **儲存空間緊張** — syno-lvm 使用率 90%、synology-backup 86%,建議清理或擴容 +2. **備份全停用** — 三個排程都是 enabled=0,重要服務(Lydia、OpenWRT)目前無自動備份 +3. **HA 未啟用** — 單節點故障時 VM/CT 不會自動遷移 +4. **pve-02 記憶體較吃緊** — 70% 使用率,跑了 PBS + K3s (8GB) + Lydia prod/test