Change:
https://k8s- The following tests are broken: NVIDIA GPU Device Plugin PriorityLocalStorageEvictionOrdering PriorityMemoryEvictionOrdering Looks like some new validation was to prevent two things: PodPriority directly system-critical priority classes outside of the kube-system namespace. To fix this, we need to create new priority classes for these tests. cc /kind failing-test /sig node /sig scheduling /priority important-soon
/kind bug
/assign
This doesn't appear to have fixed the tests. Tests now panic during the Aftereach in which the PriorityClass is deleted. /reopen
Panic:
Issues go stale after 90d of inactivity. Mark the issue as fresh with . Stale issues rot after an additional 30d of inactivity and eventually close. If this issue is safe to close now please do so with . Send feedback to sig-testing, kubernetes/test-infra and/or . /lifecycle stale
Stale issues rot after 30d of inactivity. Mark the issue as fresh with . Rotten issues close after an additional 30d of inactivity. If this issue is safe to close now please do so with . Send feedback to sig-testing, kubernetes/test-infra and/or . /lifecycle rotten
Rotten issues close after 30d of inactivity. Reopen the issue with . Mark the issue as fresh with . Send feedback to sig-testing, kubernetes/test-infra and/or . /close
Closing this issue. <detailsIn response to : Rotten issues close after 30d of inactivity. Reopen the issue with . Mark the issue as fresh with . /close Instructions for interacting with me using PR comments are available . If you have questions or suggestions related to my behavior, please file an issue against the repository. </details

Discussion:
} // NVIDIADevicePlugin returns the official Google Device Plugin pod for NVIDIA GPU in GKE <del> func NVIDIADevicePlugin(ns string) *v1.Pod { </del> <ins> func NVIDIADevicePlugin() *v1.Pod { </ins> ds, err := DsFromManifest(GPUDevicePluginDSYAML) Expect(err).NotTo(HaveOccurred()) p := &v1.Pod{ ObjectMeta: metav1.ObjectMeta{ Name:      "device-plugin-nvidia-gpu-" + string(uuid.NewUUID()), <del> Namespace: ns, </del> <ins> Namespace: metav1.NamespaceSystem, </ins> }, Spec: ds.Spec.Template.Spec,

"//pkg/kubelet/types:go_default_library", "//pkg/security/apparmor:go_default_library", "//staging/src/k8s.io/api/core/v1:go_default_library", <ins> "//staging/src/k8s.io/api/scheduling/v1beta1:go_default_library", </ins> "//staging/src/k8s.io/apimachinery/pkg/api/equality:go_default_library", "//staging/src/k8s.io/apimachinery/pkg/api/errors:go_default_library", "//staging/src/k8s.io/apimachinery/pkg/api/resource:go_default_library",

"time" "k8s.io/api/core/v1" <ins> schedulerapi "k8s.io/api/scheduling/v1beta1" "k8s.io/apimachinery/pkg/api/errors" </ins> "k8s.io/apimachinery/pkg/api/resource" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/fields"

expectedNodeCondition := v1.NodeMemoryPressure expectedStarvedResource := v1.ResourceMemory pressureTimeout := 10 * time.Minute <ins> highPriorityClassName := f.BaseName + "-high-priority" highPriority := int32(999999999) BeforeEach(func() { _, err := f.ClientSet.SchedulingV1beta1().PriorityClasses().Create(&schedulerapi.PriorityClass{ObjectMeta: metav1.ObjectMeta{Name: highPriorityClassName}, Value: highPriority}) Expect(err == nil || errors.IsAlreadyExists(err)).To(BeTrue()) }) AfterEach(func() { err := f.ClientSet.SchedulingV1beta1().PriorityClasses().Delete(highPriorityClassName, &metav1.DeleteOptions{}) Expect(err).NotTo(HaveOccurred()) }) </ins> Context(fmt.Sprintf(testContextFmt, expectedNodeCondition), func() { tempSetCurrentKubeletConfig(f, func(initialConfig *kubeletconfig.KubeletConfiguration) { initialConfig.FeatureGates[string(features.PodPriority)] = true

}), }, } <del> systemPriority := int32(2147483647) specs[1].pod.Spec.Priority = &systemPriority </del> <ins> specs[1].pod.Spec.PriorityClassName = highPriorityClassName </ins> runEvictionTest(f, pressureTimeout, expectedNodeCondition, expectedStarvedResource, logMemoryMetrics, specs) }) })

expectedNodeCondition := v1.NodeDiskPressure expectedStarvedResource := v1.ResourceEphemeralStorage pressureTimeout := 10 * time.Minute <ins> highPriorityClassName := f.BaseName + "-high-priority" highPriority := int32(999999999) BeforeEach(func() { _, err := f.ClientSet.SchedulingV1beta1().PriorityClasses().Create(&schedulerapi.PriorityClass{ObjectMeta: metav1.ObjectMeta{Name: highPriorityClassName}, Value: highPriority}) Expect(err == nil || errors.IsAlreadyExists(err)).To(BeTrue()) }) AfterEach(func() { err := f.ClientSet.SchedulingV1beta1().PriorityClasses().Delete(highPriorityClassName, &metav1.DeleteOptions{}) Expect(err).NotTo(HaveOccurred()) }) </ins> Context(fmt.Sprintf(testContextFmt, expectedNodeCondition), func() { tempSetCurrentKubeletConfig(f, func(initialConfig *kubeletconfig.KubeletConfiguration) { initialConfig.FeatureGates[string(features.PodPriority)] = true

}), }, } <del> systemPriority := int32(2147483647) specs[1].pod.Spec.Priority = &systemPriority </del> <ins> specs[1].pod.Spec.PriorityClassName = highPriorityClassName </ins> runEvictionTest(f, pressureTimeout, expectedNodeCondition, expectedStarvedResource, logDiskMetrics, specs) }) })

Context("DevicePlugin", func() { var devicePluginPod *v1.Pod <ins> var err error </ins> BeforeEach(func() { By("Ensuring that Nvidia GPUs exists on the node") if !checkIfNvidiaGPUsExistOnNode() {

} By("Creating the Google Device Plugin pod for NVIDIA GPU in GKE") <del> devicePluginPod = f.PodClient().CreateSync(framework.NVIDIADevicePlugin(f.Namespace.Name)) </del> <ins> devicePluginPod, err = f.ClientSet.CoreV1().Pods(metav1.NamespaceSystem).Create(framework.NVIDIADevicePlugin()) framework.ExpectNoError(err) </ins> By("Waiting for GPUs to become available on the local node") Eventually(func() bool {

Expect(devId1).To(Not(Equal(devId2))) By("Deleting device plugin.") <del> f.PodClient().Delete(devicePluginPod.Name, &metav1.DeleteOptions{}) </del> <ins> f.ClientSet.CoreV1().Pods(metav1.NamespaceSystem).Delete(devicePluginPod.Name, &metav1.DeleteOptions{}) </ins> By("Waiting for GPUs to become unavailable on the local node") Eventually(func() bool { node, err := f.ClientSet.CoreV1().Nodes().Get(framework.TestContext.NodeName, metav1.GetOptions{})