Storage
Local-path provisioner, persistent volumes, CSI drivers, backups.
Local-Path Provisioner
Default
K3s ships local-path-provisioner — no config needed. PVCs get a hostPath volume under /var/lib/rancher/k3s/storage.
Dynamic provisioning
Any PVC without a custom storage class gets a local-path volume automatically. Useful for dev and edge.
Limitations
Local-path volumes are node-local. If the pod reschedules to another node, the data is gone.
Longhorn (Recommended for HA)
What is it
Distributed block storage built for K3s — replicates volumes across nodes. Open-source from Rancher.
Install
kubectl apply -f https://longhorn.io/deploy/longhorn.yaml — one Helm command.
Use case
Production workloads where you can't lose data on reschedule. Databases, file shares, persistent logs.
CSI Drivers
Cloud CSI
AWS EBS, Azure Disk, GCP PD — auto-installed when you run on a cloud with proper IAM.
Custom CSI
Any CSI-compliant driver works. Dell EMC PowerScale, NetApp Trident, Pure Storage — all tested with K3s.
Supported
Major cloud and on-prem providers — see the official CSI drivers list.
Backup and Restore
etcd backup
Best for HA clusters with external etcd. etcdctl snapshot save /backup/db then /usr/local/bin/k3s server --cluster-reset --cluster-reset-restore-path=/backup/db
SQLite backup
Single-file database. Just stop K3s, copy /var/lib/rancher/k3s/db/, restart.
Workload backup
Use Velero — cluster-wide backup including PVs, secrets, workloads. Compatible with K3s out of the box.