Bug 2004508 - TuneD issues with the recent ConfigParser changes.
Summary: TuneD issues with the recent ConfigParser changes.
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Node Tuning Operator
Version: 4.9
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.10.0
Assignee: Jiří Mencák
QA Contact: Simon
URL:
Whiteboard:
Depends On:
Blocks: 2004712
TreeView+ depends on / blocked
 
Reported: 2021-09-15 13:18 UTC by Jiří Mencák
Modified: 2022-03-10 16:11 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-03-10 16:10:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-node-tuning-operator pull 271 0 None open Bug 2004508: TuneD: Revert the ConfigParser changes. 2021-09-15 14:20:15 UTC
Red Hat Product Errata RHSA-2022:0056 0 None None None 2022-03-10 16:11:15 UTC

Description Jiří Mencák 2021-09-15 13:18:44 UTC
Description of problem:
TuneD recently introduced (https://github.com/redhat-performance/tuned/pull/375) changes that break certain TuneD profiles can be parsed.

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

How reproducible:
Always.

Steps to Reproduce:
Create a TuneD profile with comments not starting at the beginning of the line, such as:

[selinux]
avc_cache_threshold=8192                      # some comments

or
[sysfs]
/sys/bus/pci/devices/0000:00:00.0/power/control=on

Actual results:
Profile fails to apply correctly.

Expected results:
Profile applies correctly.

Additional info:
https://github.com/redhat-performance/tuned/issues/378

Comment 2 Simon 2021-09-16 13:41:59 UTC
$ oc project openshift-cluster-node-tuning-operator 
Now using project "openshift-cluster-node-tuning-operator" on server "https://api.skordas916a.qe.devcluster.openshift.com:6443".

$ oc get clusterversion
NAME      VERSION                              AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.10.0-0.nightly-2021-09-16-064101   True        False         92m     Cluster version is 4.10.0-0.nightly-2021-09-16-064101

$ oc get nodes
NAME                                         STATUS   ROLES    AGE    VERSION
ip-10-0-132-241.us-east-2.compute.internal   Ready    master   107m   v1.22.0-rc.0+75ee307
ip-10-0-156-73.us-east-2.compute.internal    Ready    worker   101m   v1.22.0-rc.0+75ee307
ip-10-0-173-184.us-east-2.compute.internal   Ready    master   108m   v1.22.0-rc.0+75ee307
ip-10-0-194-68.us-east-2.compute.internal    Ready    master   108m   v1.22.0-rc.0+75ee307

$ oc get pods -o wide| grep ip-10-0-156-73.us-east-2.compute.internal   # get tuned pod on worker node
tuned-8rk6h                                    1/1     Running   0          102m   10.0.156.73    ip-10-0-156-73.us-east-2.compute.internal    <none>           <none>

$ pod=tuned-8rk6h

$ cat tuned.yml 
apiVersion: tuned.openshift.io/v1
kind: Tuned
metadata:
  name: nf-conntrack-max
  namespace: openshift-cluster-node-tuning-operator
spec:
  profile:
  - data: |
      [main]
      summary=Test if user can apply custom tuning: sysctl net.netfilter.nf_conntrack_max
      include=openshift-node
      [sysctl]
      net.netfilter.nf_conntrack_max=1048578   # Here is some comment in the line
    name: nf-conntrack-max
  recommend:
  - match:
    - label: tuned.openshift.io/elasticsearch
      type: pod
    priority: 15
    profile: nf-conntrack-max

$ oc label pod $pod tuned.openshift.io/elasticsearch=
pod/tuned-8rk6h labeled

$ oc create -f tuned.yml 
tuned.tuned.openshift.io/nf-conntrack-max created

$ oc get tuned
NAME               AGE
default            109m
nf-conntrack-max   3s
rendered           109m

$ oc get profiles
NAME                                         TUNED                     APPLIED   DEGRADED   AGE
ip-10-0-132-241.us-east-2.compute.internal   openshift-control-plane   True      False      109m
ip-10-0-156-73.us-east-2.compute.internal    nf-conntrack-max          True      False      105m
ip-10-0-173-184.us-east-2.compute.internal   openshift-control-plane   True      False      109m
ip-10-0-194-68.us-east-2.compute.internal    openshift-control-plane   True      False      109m

$ oc delete tuned nf-conntrack-max 
tuned.tuned.openshift.io "nf-conntrack-max" deleted

$ oc get tuned
NAME       AGE
default    110m
rendered   110m

$ oc get profiles
NAME                                         TUNED                     APPLIED   DEGRADED   AGE
ip-10-0-132-241.us-east-2.compute.internal   openshift-control-plane   True      False      110m
ip-10-0-156-73.us-east-2.compute.internal    openshift-node            True      False      105m
ip-10-0-173-184.us-east-2.compute.internal   openshift-control-plane   True      False      110m
ip-10-0-194-68.us-east-2.compute.internal    openshift-control-plane   True      False      110m

$ cat tuned.yml 
apiVersion: tuned.openshift.io/v1
kind: Tuned
metadata:
  name: nf-conntrack-max
  namespace: openshift-cluster-node-tuning-operator
spec:
  profile:
  - data: |
      [main]
      summary=Test if user can apply custom tuning: sysctl net.netfilter.nf_conntrack_max
      include=openshift-node
      [sysfs]
      /sys/bus/pci/devices/0000:00:00.0/power/control=on    
    name: nf-conntrack-max
  recommend:
  - match:
    - label: tuned.openshift.io/elasticsearch
      type: pod
    priority: 15
    profile: nf-conntrack-max


$ oc create -f tuned.yml 
tuned.tuned.openshift.io/nf-conntrack-max created

$ oc get tuned
NAME               AGE
default            111m
nf-conntrack-max   5s
rendered           111m

$ oc get profiles
NAME                                         TUNED                     APPLIED   DEGRADED   AGE
ip-10-0-132-241.us-east-2.compute.internal   openshift-control-plane   True      False      111m
ip-10-0-156-73.us-east-2.compute.internal    nf-conntrack-max          True      False      107m
ip-10-0-173-184.us-east-2.compute.internal   openshift-control-plane   True      False      111m
ip-10-0-194-68.us-east-2.compute.internal    openshift-control-plane   True      False      111m

$ oc delete tuned nf-conntrack-max 
tuned.tuned.openshift.io "nf-conntrack-max" deleted

$ oc get profiles
NAME                                         TUNED                     APPLIED   DEGRADED   AGE
ip-10-0-132-241.us-east-2.compute.internal   openshift-control-plane   True      False      112m
ip-10-0-156-73.us-east-2.compute.internal    openshift-node            True      False      107m
ip-10-0-173-184.us-east-2.compute.internal   openshift-control-plane   True      False      112m
ip-10-0-194-68.us-east-2.compute.internal    openshift-control-plane   True      False      112m

$ cat tuned.yml 
apiVersion: tuned.openshift.io/v1
kind: Tuned
metadata:
  name: nf-conntrack-max
  namespace: openshift-cluster-node-tuning-operator
spec:
  profile:
  - data: |
      [main]
      summary=Test if user can apply custom tuning: sysctl net.netfilter.nf_conntrack_max
      include=openshift-node
      [sysfs]
      /sys/bus/pci/devices/0000:00:00.0/power/control=on  # some comment also here
    name: nf-conntrack-max
  recommend:
  - match:
    - label: tuned.openshift.io/elasticsearch
      type: pod
    priority: 15
    profile: nf-conntrack-max


$ oc create -f tuned.yml 
tuned.tuned.openshift.io/nf-conntrack-max created

$ oc get tuneds.tuned.openshift.io 
NAME               AGE
default            112m
nf-conntrack-max   7s
rendered           112m

$ oc get profiles.tuned.openshift.io 
NAME                                         TUNED                     APPLIED   DEGRADED   AGE
ip-10-0-132-241.us-east-2.compute.internal   openshift-control-plane   True      False      112m
ip-10-0-156-73.us-east-2.compute.internal    nf-conntrack-max          True      False      108m
ip-10-0-173-184.us-east-2.compute.internal   openshift-control-plane   True      False      112m
ip-10-0-194-68.us-east-2.compute.internal    openshift-control-plane   True      False      112m

Comment 5 errata-xmlrpc 2022-03-10 16:10:42 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.10.3 security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2022:0056


Note You need to log in before you can comment on or make changes to this bug.