Uploaded image for project: 'OpenShift Bugs'
  1. OpenShift Bugs
  2. OCPBUGS-32469

NTO operand reloads TuneD unnecessarily twice

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • 4.16.0
    • 4.13.z, 4.12.z, 4.14.z, 4.15.z, 4.16
    • Node Tuning Operator
    • None
    • Important
    • No
    • False
    • Hide

      None

      Show
      None

      Description of problem:

      
      TuneD unnecessarily restarts twice when both current TuneD profile changes and when a new TuneD profile is selected.
      
          

      Version-Release number of selected component (if applicable):

      
      All NTO versions are affected.
      
          

      How reproducible:

      
      Depends on the order of k8s object updates (races), but nearly 100% reproducible.
      
          

      Steps to Reproduce:

          1. Install SNO 
          2. Label your SNO node with label "profile"
          3. Create the following CR:
      
      apiVersion: tuned.openshift.io/v1
      kind: Tuned
      metadata:
        name: openshift-profile
        namespace: openshift-cluster-node-tuning-operator
      spec:
        profile:
        - data: |
            [main]
            summary=Custom OpenShift profile 1
            include=openshift-node
            [sysctl]
            kernel.pty.max=4096
          name: openshift-profile-1
        - data: |
            [main]
            summary=Custom OpenShift profile 2
            include=openshift-node
            [sysctl]
            kernel.pty.max=8192
          name: openshift-profile-2
        recommend:
        - match:
          - label: profile
          priority: 20
          profile: openshift-profile-1
      
          4. Apply the following CR:
      
      apiVersion: tuned.openshift.io/v1
      kind: Tuned
      metadata:
        name: openshift-profile
        namespace: openshift-cluster-node-tuning-operator
      spec:
        profile:
        - data: |
            [main]
            summary=Custom OpenShift profile 1
            include=openshift-node
            [sysctl]
            kernel.pty.max=8192
          name: openshift-profile-1
        - data: |
            [main]
            summary=Custom OpenShift profile 2
            include=openshift-node
            [sysctl]
            kernel.pty.max=8192
          name: openshift-profile-2
        recommend:
        - match:
          - label: profile
          priority: 20
          profile: openshift-profile-2
      
          

      Actual results:

      
      You'll see two restarts/applications of the openshift-profile-1
      
      $ cat tuned-operand.log |grep "profile-1' applied"
      2024-04-19 06:10:54,685 INFO     tuned.daemon.daemon: static tuning from profile 'openshift-profile-1' applied
      2024-04-19 06:13:23,627 INFO     tuned.daemon.daemon: static tuning from profile 'openshift-profile-1' applied
      
      
          

      Expected results:

      
      Only 1 application of openshift-profile-1:
      
      $ cat tuned-operand.log |grep "profile-1' applied"
      2024-04-19 07:20:31,600 INFO     tuned.daemon.daemon: static tuning from profile 'openshift-profile-1' applied
      
      
          

      Additional info:

      
          

            jmencak Jiri Mencak
            jmencak Jiri Mencak
            Liquan Cui Liquan Cui
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: