Hello! I'm side loading about 40GB of images in /...
# rke2
q
Hello! I'm side loading about 40GB of images in /var/lib/rancher/rke2/agent/images and sometimes rke2-server fails to start with an apparent 15 minute timeout. I'm looking to confirm my suspicion that cramming too many images in causes this. This is the error:
Copy code
"Failed to get request handlers from apiserver: context deadline exceeded, failed to get apiserver /readyz status: Get \"<<https://127.0.0.1:6443/readyz?timeout=15m0s>>\": dial tcp 127.0.0.1:6443: connect: connection refused"
among dozens of other messages about importing images.
c
yeah don’t do that, that’s too much
Use a registry mirror, or (on recent releases) add the images later, after it’s started and let it import them then
anything that’s there when it starts is in the critical path for service startup
If you
touch var/lib/rancher/rke2/agent/images/cache.json
it won’t re-import tarballs that haven’t changed.
q
Ok, thank you for your quick reply. I think I need to upgrade rke2 to use cache.json. I think that will be my "quick fix" so that rke2-server will eventually come up even if it fails a few times because it's importing images. Long term it seems like I have to use a registry mirror though. I'm in an air gapped environment so I think each node would need its own local mirror. I'll have to research that some.