diff --git a/build/dependencies.yaml b/build/dependencies.yaml index bdb87d7b62d..de5da0a4e9d 100644 --- a/build/dependencies.yaml +++ b/build/dependencies.yaml @@ -109,23 +109,12 @@ dependencies: match: registry.k8s.io/e2e-test-images/agnhost:\d+\.\d+\.\d+ - name: "node-problem-detector" - version: 1.34.0 + version: 1.35.2 refPaths: - path: test/e2e_node/image_list.go match: const defaultImage - path: test/kubemark/resources/hollow-node_template.yaml match: registry.k8s.io/node-problem-detector/node-problem-detector - - path: cluster/addons/node-problem-detector/npd.yaml - match: registry.k8s.io/node-problem-detector/node-problem-detector - - path: cluster/addons/node-problem-detector/npd.yaml - match: app.kubernetes.io/version - # TODO(dims): Ensure newer versions get uploaded to - # - https://console.cloud.google.com/storage/browser/gke-release/winnode/node-problem-detector - # - https://gcsweb.k8s.io/gcs/kubernetes-release/node-problem-detector/ - # and then the following references get fixed. - # - - path: cluster/gce/gci/configure.sh - match: DEFAULT_NPD_VERSION= #- path: cluster/gce/windows/k8s-node-setup.psm1 # match: DEFAULT_NPD_VERSION diff --git a/cluster/addons/node-problem-detector/MAINTAINERS.md b/cluster/addons/node-problem-detector/MAINTAINERS.md deleted file mode 100644 index d2fd3b65127..00000000000 --- a/cluster/addons/node-problem-detector/MAINTAINERS.md +++ /dev/null @@ -1,4 +0,0 @@ -# Maintainers - -Random-Liu -wangzhen127 diff --git a/cluster/addons/node-problem-detector/OWNERS b/cluster/addons/node-problem-detector/OWNERS deleted file mode 100644 index 66cec0a3619..00000000000 --- a/cluster/addons/node-problem-detector/OWNERS +++ /dev/null @@ -1,8 +0,0 @@ -# See the OWNERS docs at https://go.k8s.io/owners - -approvers: - - Random-Liu - - wangzhen127 -reviewers: - - Random-Liu - - wangzhen127 diff --git a/cluster/addons/node-problem-detector/README.md b/cluster/addons/node-problem-detector/README.md deleted file mode 100644 index 220ab1315d0..00000000000 --- a/cluster/addons/node-problem-detector/README.md +++ /dev/null @@ -1,7 +0,0 @@ -# Node Problem Detector -============== - -Node Problem Detector is a DaemonSet running on each node, detecting node -problems. - -Learn more at: https://github.com/kubernetes/node-problem-detector diff --git a/cluster/addons/node-problem-detector/kubelet-user-standalone/npd-binding.yaml b/cluster/addons/node-problem-detector/kubelet-user-standalone/npd-binding.yaml deleted file mode 100644 index 3d34fef427c..00000000000 --- a/cluster/addons/node-problem-detector/kubelet-user-standalone/npd-binding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: kubelet-user-npd-binding - labels: - kubernetes.io/cluster-service: "true" - addonmanager.kubernetes.io/mode: Reconcile -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: system:node-problem-detector -subjects: -- apiGroup: rbac.authorization.k8s.io - kind: User - name: kubelet diff --git a/cluster/addons/node-problem-detector/npd.yaml b/cluster/addons/node-problem-detector/npd.yaml deleted file mode 100644 index 838106be1bf..00000000000 --- a/cluster/addons/node-problem-detector/npd.yaml +++ /dev/null @@ -1,96 +0,0 @@ -apiVersion: v1 -kind: ServiceAccount -metadata: - name: node-problem-detector - namespace: kube-system - labels: - kubernetes.io/cluster-service: "true" - addonmanager.kubernetes.io/mode: Reconcile ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: npd-binding - labels: - kubernetes.io/cluster-service: "true" - addonmanager.kubernetes.io/mode: Reconcile -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: system:node-problem-detector -subjects: -- kind: ServiceAccount - name: node-problem-detector - namespace: kube-system ---- -apiVersion: apps/v1 -kind: DaemonSet -metadata: - name: node-problem-detector - namespace: kube-system - labels: - app.kubernetes.io/name: node-problem-detector - app.kubernetes.io/version: v1.34.0 - addonmanager.kubernetes.io/mode: Reconcile -spec: - selector: - matchLabels: - app.kubernetes.io/name: node-problem-detector - app.kubernetes.io/version: v1.34.0 - template: - metadata: - labels: - app.kubernetes.io/name: node-problem-detector - app.kubernetes.io/version: v1.34.0 - spec: - nodeSelectors: - kubernetes.io/os: linux - containers: - - name: node-problem-detector - image: registry.k8s.io/node-problem-detector/node-problem-detector:v1.34.0 - command: - - "/bin/sh" - - "-c" - - "exec /node-problem-detector --logtostderr --config.system-log-monitor=/config/kernel-monitor.json,/config/systemd-monitor.json --config.custom-plugin-monitor=/config/kernel-monitor-counter.json,/config/systemd-monitor-counter.json --config.system-stats-monitor=/config/system-stats-monitor.json >>/var/log/node-problem-detector.log 2>&1" - securityContext: - privileged: true - resources: - limits: - cpu: "200m" - memory: "100Mi" - requests: - cpu: "20m" - memory: "20Mi" - env: - - name: NODE_NAME - valueFrom: - fieldRef: - fieldPath: spec.nodeName - volumeMounts: - - name: log - mountPath: /var/log - - name: kmsg - mountPath: /dev/kmsg - readOnly: true - - name: localtime - mountPath: /etc/localtime - readOnly: true - volumes: - - name: log - hostPath: - path: /var/log/ - - name: kmsg - hostPath: - path: /dev/kmsg - - name: localtime - hostPath: - path: /etc/localtime - type: "FileOrCreate" - serviceAccountName: node-problem-detector - tolerations: - - operator: "Exists" - effect: "NoExecute" - - operator: "Exists" - effect: "NoSchedule" - - key: "CriticalAddonsOnly" - operator: "Exists" diff --git a/cluster/addons/node-problem-detector/standalone/npd-binding.yaml b/cluster/addons/node-problem-detector/standalone/npd-binding.yaml deleted file mode 100644 index d7d64a63684..00000000000 --- a/cluster/addons/node-problem-detector/standalone/npd-binding.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: npd-binding - labels: - kubernetes.io/cluster-service: "true" - addonmanager.kubernetes.io/mode: Reconcile -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: system:node-problem-detector -subjects: -- apiGroup: rbac.authorization.k8s.io - kind: User - name: system:node-problem-detector diff --git a/cluster/gce/gci/configure-helper.sh b/cluster/gce/gci/configure-helper.sh index 505ef63ad34..14552a7ef65 100755 --- a/cluster/gce/gci/configure-helper.sh +++ b/cluster/gce/gci/configure-helper.sh @@ -2966,16 +2966,6 @@ function start-kube-addons { update-event-exporter ${event_exporter_yaml} update-prometheus-to-sd-parameters ${event_exporter_yaml} fi - if [[ "${ENABLE_NODE_PROBLEM_DETECTOR:-}" == "daemonset" ]]; then - setup-addon-manifests "addons" "node-problem-detector" - fi - if [[ "${ENABLE_NODE_PROBLEM_DETECTOR:-}" == "standalone" ]]; then - # Setup role binding(s) for standalone node problem detector. - if [[ -n "${NODE_PROBLEM_DETECTOR_TOKEN:-}" ]]; then - setup-addon-manifests "addons" "node-problem-detector/standalone" - fi - setup-addon-manifests "addons" "node-problem-detector/kubelet-user-standalone" "node-problem-detector" - fi if echo "${ADMISSION_CONTROL:-}" | grep -q "LimitRanger"; then setup-addon-manifests "admission-controls" "limit-range" "gce" fi diff --git a/cluster/gce/gci/configure.sh b/cluster/gce/gci/configure.sh index b61f85cdf72..451f62e31b4 100644 --- a/cluster/gce/gci/configure.sh +++ b/cluster/gce/gci/configure.sh @@ -27,9 +27,7 @@ set -o pipefail DEFAULT_CNI_VERSION='v1.9.1' # CNI HASH for amd64 sha512 DEFAULT_CNI_HASH='3ea8a76852b7ddc62c087a34cccca2cb29822ca24214928cd172b28bf9d1486000ba3eb71a156445af31ff6a92c1dc3e01e702546c6ee016ef13fae06ccfb8fc' -DEFAULT_NPD_VERSION='v1.34.0' -DEFAULT_NPD_HASH_AMD64='3c55ff6ffadd77dbc3df3774d13164587103ca87c8b6914f5c71c87d8f498b78621e0c96538bb3c69f8f1b4194a6da553aa56b1b52001a7d9a67776ac24e80bd' -DEFAULT_NPD_HASH_ARM64='ca1d34e64b80f6b2bdf86cfde95154122d6e14c707a748ea6fc414a55f391b1bb572a96b6b2c285996af0232917fa87e14e037125aa03a62247383af3e48c095' + DEFAULT_CRICTL_VERSION='v1.36.0' DEFAULT_CRICTL_AMD64_SHA512='43ac5425d264547bc9d9c9e31c74624d9c2a63bf7de4e77fe79517e0c927ea77ee3951a2f662920bc771599a0dc4f2859b6225c3621c7cafff952e63c83d686d' DEFAULT_CRICTL_ARM64_SHA512='485aa86f327c23cb0508e814e568bda793d291865c5cec3337ae5467a51898e9ab21a6bd38b73a6b219058bb34c9b4e7128e57360a2552b74a552e7ea1936f32' @@ -293,56 +291,6 @@ function install-gci-mounter-tools { mkdir -p "${CONTAINERIZED_MOUNTER_HOME}/rootfs/var/lib/kubelet" } -# Install node problem detector binary. -function install-node-problem-detector { - if [[ -n "${NODE_PROBLEM_DETECTOR_VERSION:-}" ]]; then - local -r npd_version="${NODE_PROBLEM_DETECTOR_VERSION}" - local -r npd_hash="${NODE_PROBLEM_DETECTOR_TAR_HASH}" - else - local -r npd_version="${DEFAULT_NPD_VERSION}" - case "${HOST_PLATFORM}/${HOST_ARCH}" in - linux/amd64) - local -r npd_hash="${DEFAULT_NPD_HASH_AMD64}" - ;; - linux/arm64) - local -r npd_hash="${DEFAULT_NPD_HASH_ARM64}" - ;; - # no other architectures are supported currently. - # Assumption is that this script only runs on linux, - # see cluster/gce/windows/k8s-node-setup.psm1 for windows - # https://github.com/kubernetes/node-problem-detector/releases/ - *) - echo "Unrecognized version and platform/arch combination:" - echo "$DEFAULT_NPD_VERSION $HOST_PLATFORM/$HOST_ARCH" - echo "Set NODE_PROBLEM_DETECTOR_VERSION and NODE_PROBLEM_DETECTOR_TAR_HASH to overwrite" - exit 1 - ;; - esac - fi - local -r npd_tar="node-problem-detector-${npd_version}-${HOST_PLATFORM}_${HOST_ARCH}.tar.gz" - - if is-preloaded "${npd_tar}" "${npd_hash}"; then - echo "${npd_tar} is preloaded." - return - fi - - if [[ -n "${NODE_PROBLEM_DETECTOR_RELEASE_PATH:-}" ]]; then - echo "Downloading ${npd_tar} from ${NODE_PROBLEM_DETECTOR_RELEASE_PATH}." - local -r download_path="${NODE_PROBLEM_DETECTOR_RELEASE_PATH}/node-problem-detector/${npd_tar}" - else - echo "Downloading ${npd_tar} from github." - local -r download_path="https://github.com/kubernetes/node-problem-detector/releases/download/${npd_version}/${npd_tar}" - fi - download-or-bust "${npd_hash}" "${download_path}" - local -r npd_dir="${KUBE_HOME}/node-problem-detector" - mkdir -p "${npd_dir}" - tar xzf "${KUBE_HOME}/${npd_tar}" -C "${npd_dir}" --overwrite - mv "${npd_dir}/bin"/* "${KUBE_BIN}" - chmod a+x "${KUBE_BIN}/node-problem-detector" - rmdir "${npd_dir}/bin" - rm -f "${KUBE_HOME}/${npd_tar}" -} - function install-cni-binaries { local -r cni_version=${CNI_VERSION:-$DEFAULT_CNI_VERSION} if [[ -n "${CNI_VERSION:-}" ]]; then @@ -795,11 +743,6 @@ function install-kube-binary-config { mv "${KUBE_HOME}/kubernetes/kubernetes-src.tar.gz" "${KUBE_HOME}" fi - if [[ "${KUBERNETES_MASTER:-}" == "false" ]] && \ - [[ "${ENABLE_NODE_PROBLEM_DETECTOR:-}" == "standalone" ]]; then - log-wrap "InstallNodeProblemDetector" install-node-problem-detector - fi - if [[ "${NETWORK_PROVIDER:-}" == "kubenet" ]] || \ [[ "${NETWORK_PROVIDER:-}" == "cni" ]]; then log-wrap "InstallCNIBinaries" install-cni-binaries diff --git a/test/e2e_node/image_list.go b/test/e2e_node/image_list.go index 91f13a18c5f..cc469df0046 100644 --- a/test/e2e_node/image_list.go +++ b/test/e2e_node/image_list.go @@ -92,7 +92,7 @@ func updateImageAllowList(ctx context.Context) { } func getNodeProblemDetectorImage() string { - const defaultImage string = "registry.k8s.io/node-problem-detector/node-problem-detector:v1.34.0" + const defaultImage string = "registry.k8s.io/node-problem-detector/node-problem-detector:v1.35.2" image := os.Getenv("NODE_PROBLEM_DETECTOR_IMAGE") if image == "" { image = defaultImage diff --git a/test/kubemark/resources/hollow-node_template.yaml b/test/kubemark/resources/hollow-node_template.yaml index 1a51acb7a61..a6cc19c889d 100644 --- a/test/kubemark/resources/hollow-node_template.yaml +++ b/test/kubemark/resources/hollow-node_template.yaml @@ -99,7 +99,7 @@ spec: cpu: {{hollow_proxy_millicpu}}m memory: {{hollow_proxy_mem_Ki}}Ki - name: hollow-node-problem-detector - image: registry.k8s.io/node-problem-detector/node-problem-detector:v1.34.0 + image: registry.k8s.io/node-problem-detector/node-problem-detector:v1.35.2 env: - name: NODE_NAME valueFrom: