snap refresh microk8s fails (from v1.18.2)
See original GitHub issueUbuntu 18.04, currently on:
installed: v1.18.2 (1378) 201MB classic
snap refresh microk8s
fails with:
+ for dir in "${SNAP_DATA}/credentials/ ${SNAP_DATA}/certs/ ${SNAP_DATA}/args/ ${SNAP_DATA}/[0/1836]
"
+ chmod -R ug+rwX /var/snap/microk8s/1443/credentials/ /var/snap/microk8s/1443/certs/ /var/snap/micr
ok8s/1443/args/ /var/snap/microk8s/1443/var/lock
+ chmod -R o-rwX /var/snap/microk8s/1443/credentials/ /var/snap/microk8s/1443/certs/ /var/snap/micro
k8s/1443/args/ /var/snap/microk8s/1443/var/lock
+ getent group microk8s
+ getent group microk8s
+ chgrp microk8s -R /var/snap/microk8s/1443/credentials/ /var/snap/microk8s/1443/certs/ /var/snap/mi
crok8s/1443/args/ /var/snap/microk8s/1443/var/lock/
+ '[' -f /var/snap/microk8s/1443/args/flanneld ']'
+ grep -e etcd.socket:2379 /var/snap/microk8s/1443/args/etcd
+ grep '\-\-enable\-v2' /var/snap/microk8s/1443/args/etcd
--enable-v2=true
+ false
+ '[' -L /var/snap/microk8s/1443/bin/cilium ']'
+ '[' -e /var/snap/microk8s/1443/args/containerd-template.toml ']'
+ grep -e 'plugins.cri.registry.mirrors."local.insecure-registry.io"' /var/snap/microk8s/1443/args/c
ontainerd-template.toml
+ '[' -e /var/snap/microk8s/1443/var/lock/clustered.lock ']'
+ '[' -e /var/snap/microk8s/1443/args/flannel-template.conflist ']'
+ grep -e cniVersion /var/snap/microk8s/1443/args/flannel-template.conflist
"cniVersion": "0.3.1",
+ grep -e '\-\-timeout' /var/snap/microk8s/1443/args/cluster-agent
grep: /var/snap/microk8s/1443/args/cluster-agent: No such file or directory
+ refresh_opt_in_config timeout 240 cluster-agent
+ local opt=--timeout
+ local value=240
+ local config_file=/var/snap/microk8s/1443/args/cluster-agent
+ local replace_line=--timeout=240
++ grep -qE '^--timeout=' /var/snap/microk8s/1443/args/cluster-agent
grep: /var/snap/microk8s/1443/args/cluster-agent: No such file or directory
+ run_with_sudo /snap/microk8s/1443/bin/sed -i '$ a --timeout=240' /var/snap/microk8s/1443/args/clus
ter-agent
+ '[' -n '' ']'
+ '[' /snap/microk8s/1443/bin/sed == preserve_env ']'
+ sudo /snap/microk8s/1443/bin/sed -i '$ a --timeout=240' /var/snap/microk8s/1443/args/cluster-agent
/snap/microk8s/1443/bin/sed: can't read /var/snap/microk8s/1443/args/cluster-agent: No such file or
directory
-----)
Issue Analytics
- State:
- Created 3 years ago
- Comments:7
Top Results From Across the Web
Snap refreshes - MicroK8s
Snap refreshes. Snaps are app packages for desktop, cloud and IoT that are easy to install, secure, cross‐platform and dependency‐free and is the...
Read more >microk8s stopped working after latest ubuntu update #1193
I'm running Ubuntu 18.04.4 LTS Inspecting services Service snap.... ... I'm running v1.18.2 latest/stable version of microk8s.
Read more >Snap refresh failing due to containerd having "running apps"
Refreshing MicroK8s seems to be failing with: $ sudo snap install ./s.snap --dangerous --classic error: cannot perform the following tasks:
Read more >Snap refresh breaks MicroK8s cluster - Snapcraft forum
Hi snap people, One of our users reported that in a cluster of 5 nodes nodes two of them refreshed correctly while the...
Read more >How to control MicroK8s upgrades using a Snap Store Proxy
sudo snap refresh snapd sudo snap install snap-store-proxy ... snap list microk8s ... channels: 1.22/stable: v1.22.3 2021-11-14 (2645) 194MB ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@balchua Thanks!
worked!
I assume many users have this issue. I only noticed it because I have a watchdog monitoring the cluster and it goes down a few minutes every few hours (due to a failed update) since the last 3 days:
That’s what i suspect. Looks like an easy fix. But if you are in a hurry, you can copy the
/snap/microk8s/current/default-args/cluster-agent
to/var/snap/microk8s/current/args/
. Then try to do refresh.