https://rancher.com/ logo
Title
s

shy-tent-66642

12/08/2022, 11:03 AM
Hi All, The (mistakenly placed) comma (,) between enviormental variables while you setup k3s via script install shows clsuter as ready. But do not allow to pull any container images at all.
root@denver-metal-242:~# curl -sfL <https://get.k3s.io> | INSTALL_K3S_EXEC="server --disable traefik,servicelb", INSTALL_K3S_VERSION={v1.25.4+k3s1} sh -
[INFO]  Using {v1.25.4+k3s1} as release
[INFO]  Downloading hash <https://github.com/k3s-io/k3s/releases/download/{v1.25.4+k3s1}/sha256sum-amd64.txt>
[INFO]  Downloading binary <https://github.com/k3s-io/k3s/releases/download/{v1.25.4+k3s1}/k3s>
[INFO]  Verifying binary download
[INFO]  Installing k3s to /usr/local/bin/k3s
[INFO]  Skipping installation of SELinux RPM
[INFO]  Creating /usr/local/bin/kubectl symlink to k3s
[INFO]  Creating /usr/local/bin/crictl symlink to k3s
[INFO]  Creating /usr/local/bin/ctr symlink to k3s
[INFO]  Creating killall script /usr/local/bin/k3s-killall.sh
[INFO]  Creating uninstall script /usr/local/bin/k3s-uninstall.sh
[INFO]  env: Creating environment file /etc/systemd/system/k3s.service.env
[INFO]  systemd: Creating service file /etc/systemd/system/k3s.service
[INFO]  systemd: Enabling k3s unit
Created symlink /etc/systemd/system/multi-user.target.wants/k3s.service → /etc/systemd/system/k3s.service.
[INFO]  systemd: Starting k3s
Try
kubectl get nodes
and you can see clsuter ready. Try to run a simple pod and it remains in pending state forever.
crictl img
returns nothign at all. (which means even though 1 node clsuter is setup, it simply can not download any container images) Feel free to cross check. Run same command w/o comma and everything works as expected.
root@denver-metal-242:~# curl -sfL <https://get.k3s.io> | INSTALL_K3S_EXEC="server --disable traefik,servicelb" INSTALL_K3S_VERSION={v1.25.4+k3s1} sh -
Why can't there be proper error if one runs wrong command/puts wrong value in install script command.
c

creamy-pencil-82913

12/08/2022, 11:16 AM
The install script doesn’t do any syntax checking. It is literally just an install shell script. It passes the args through to the actual K3s service, which was probably logging some errors to the service log.
I am more surprised that
INSTALL_K3S_VERSION={v1.25.4+k3s1}
worked
why the {} around it?
s

shy-tent-66642

12/08/2022, 11:25 AM
No specific reason for {}. Just thought since this version is alphanumeric...may be good choice.
Where are service logs located?
c

creamy-pencil-82913

12/08/2022, 4:15 PM
journald