Comments (11)
Some progress on this - #39 moves us towards supporting CentOS/RHEL without external scripts...
from kured.
PR #77 Seems to work ok and it would be great if someone is able to review it and merge it. Is that possible? @awh?
from kured.
Thanks for the report @rsohn. I like your idea of specifying a command, but sadly kured is running inside a container - it has neither access to arbitrary executables in the host filesystem, nor the sources of information such an executable might be using to determine if a reboot is required. You'll note that for the Debian/Ubuntu case the daemonset bind mounts /var/run
into the container so that it can detect the presence of the sentinel file in the host - we would have to do something similar here after working out where needs-restarting
is getting its information from. We may also have to include a copy of needs-restarting
in the kured container image. In the meantime your workaround is sound, I will update the docs until we can do better.
from kured.
@rsohn I cobbled together a restart script for my Fedora and CentOS lab systems. I'm installing and activating it with ansible and its working like a champ. Not sure if this will be of any value to you but thought I would pass it on.
from kured.
With #39 on board - what more is needed?
from kured.
It appears to me to be complete.
from kured.
So . basically this issue should be closed as fixed?
from kured.
Maybe I'm missing something but if I look at the changes introduced by #39, it doesn't let you execute a binary.
@awh, should we introduce a new flag for this purpose? I can help if needed
from kured.
Some progress on this - #39 moves us towards supporting CentOS/RHEL without external scripts...
@awh can you please elaborate? We still cannot use needs-restarting -r
as sentinel.
The current implementation is using sentinelCmd := newCommand("/usr/bin/nsenter", "-m/proc/1/ns/mnt", "--", "/usr/bin/test", "-f", rebootSentinel)
Some tests to confirm it doesn't work with a command:
[root@host ~]# needs-restarting -r
No core libraries or services have been updated.
Reboot is probably not necessary.
[root@host ~]# echo $?
0
[root@host ~]# test -f 'needs-restarting -r'
[root@host ~]# echo $?
1
[root@host ~]# test -f '! needs-restarting -r'
[root@host ~]# echo $?
1
[root@host ~]# needs-restarting -r
Core libraries or services have been updated:
systemd -> 219-62.el7_6.6
Reboot is required to ensure that your system benefits from these updates.
More information:
https://access.redhat.com/solutions/27943
[root@host ~]# echo $?
1
[root@host ~]# test -f '! needs-restarting -r'
[root@host ~]# echo $?
1
[root@host ~]# test -f 'needs-restarting -r'
[root@host ~]# echo $?
1
Can we have a successful implementation to depend on a return code of needs-restarting -r
or you cannot bypass some limitation(s)?
from kured.
It seems like "test
" might not be the right mechanism to use here. Certainly, the -f
option is a problem, as that checks for the existence of a file, rather than a return code.
Perhaps eval 'needs-restarting -r >/dev/null'
is closer to what is needed here?
from kured.
This issue was automatically considered stale due to lack of activity. Please update it and/or join our slack channels to promote it, before it automatically closes (in 7 days).
from kured.
Related Issues (20)
- Core dump when executing nsenter command HOT 1
- Immutable (read-only) root filesystem should be enforced for containers
- Kubernetes clusters should disable auto mounting API credentials HOT 2
- Usage of host networking and ports should be restricted on stage and perf clusters on kubernetes clusters
- Containers sharing sensitive host namespaces should be avoided HOT 4
- Kured Helm hostNetwork problem HOT 2
- stderr/stdout of custom reboot command HOT 1
- Team Kured is looking for help! HOT 1
- [Feature request] Use cloud APIs to increase node pool size before reboots and decrease after HOT 6
- [Bug] The new dockerhub yaml is broken, ServiceAccount is declared twice HOT 2
- Add Support for Kubernetes 1.28.0
- Unable to receive teams notification. We have the http_proxy as environment variable in kured pod HOT 4
- HashiCorp license change to BSL HOT 2
- Lock TTL not being honored HOT 5
- Build fails on aarch64
- Kured pods crash looping on clusters running Cilium Network plugin HOT 2
- Kured pods are not deployed to all nodes having taints on it in AKS ckuster HOT 3
- KURED supportability of the 6.2 kernel version HOT 2
- kured cordon node before checking if just 1 up HOT 8
- [DOC] Make Control Plane use kured
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kured.