K3s: Move Data Folder
janusworx.com·12w


Problem

My main SSD is to small to hold all my kubernetes and K3s shenanigans. (It’s only about 512gb) So I need a way to move my K3s data folder out to my big HDD.

Caution!

Before you do any of the following, make sure to stop the cluster with: sudo systemctl stop k3s

Solution

K3s supports having acustom data directory, by letting me specify a data-dir. I decided to specify it in the K3s config file at /etc/rancher/k3s/config. If it isn’t there (as it wasn’t in my case), just create one. You’ll need to do this as the root user. This is what I now have in there.

data-dir: /BIGHDD/rancher/k3s

And then, I …

  1. Created a rancher directory in my …

Similar Posts

Loading similar posts...

Keyboard Shortcuts

Navigation
Next / previous item
j/k
Open post
oorEnter
Preview post
v
Post Actions
Love post
a
Like post
l
Dislike post
d
Undo reaction
u
Recommendations
Add interest / feed
Enter
Not interested
x
Go to
Home
gh
Interests
gi
Feeds
gf
Likes
gl
History
gy
Changelog
gc
Settings
gs
Browse
gb
Search
/
General
Show this help
?
Submit feedback
!
Close modal / unfocus
Esc

Press ? anytime to show this help