Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
a7bf00bb
Unverified
Commit
a7bf00bb
authored
Dec 04, 2020
by
Brian Downs
Committed by
GitHub
Dec 04, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update uninstall script to remove mount point path after umount (#2542)
* update uninstall script to remove mount point path after umount
parent
eb3e4c15
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
6 deletions
+9
-6
install.sh
install.sh
+9
-6
No files found.
install.sh
View file @
a7bf00bb
...
...
@@ -606,14 +606,17 @@ getshims() {
killtree
$(
{
set
+x
;
}
2>/dev/null
;
getshims
;
set
-x
)
do_unmount() {
awk -v path="
$1
" '
$2
~ ("^" path) { print
$2
}' /proc/self/mounts | sort -r | xargs -r -t -n 1
umount
do_unmount
_and_remove
() {
awk -v path="
$1
" '
$2
~ ("^" path) { print
$2
}' /proc/self/mounts | sort -r | xargs -r -t -n 1
sh -c 'umount "
$0
" && rm -rf "
$0
"'
}
do_unmount '/run/k3s'
do_unmount '/var/lib/rancher/k3s'
do_unmount '/var/lib/kubelet/pods'
do_unmount '/run/netns/cni-'
do_unmount_and_remove '/run/k3s'
do_unmount_and_remove '/var/lib/rancher/k3s'
do_unmount_and_remove '/var/lib/kubelet/pods'
do_unmount_and_remove '/run/netns/cni-'
# Remove CNI namespaces
ip netns show 2>/dev/null | grep cni- | xargs -r -t -n 1 ip netns delete
# Delete network interface(s) that match 'master cni0'
ip link show 2>/dev/null | grep 'master cni0' | while read ignore iface ignore; do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment