Skip to content
This repository was archived by the owner on Feb 8, 2024. It is now read-only.

Conversation

@d-nayak
Copy link
Contributor

@d-nayak d-nayak commented Sep 6, 2022

Problem:
Codacy flags issues in hax.c C code

Solution:

  1. Some motr struct asserts were called after the local variable assignments were done.
  2. 1 variable (obj_name) had wider scope than necessary.

Signed-off-by: Deepak Nayak [email protected]

Solution:
1. Some motr struct asserts were called after the local variable assignments were done.
2. 1 variable (obj_name) had wider scope than necessary.

Signed-off-by: Deepak Nayak <[email protected]>
Signed-off-by: Deepak Nayak <[email protected]>
@d-nayak
Copy link
Contributor Author

d-nayak commented Sep 9, 2022

The 3 issues that Codacy had flagged in hax.c have been resolved as per latest Codacy report:

https://app.codacy.com/gh/Seagate/cortx-hare/pullRequest?prid=10117925&bid=30956459

@d-nayak
Copy link
Contributor Author

d-nayak commented Sep 9, 2022

@supriyachavan4398 - please test it on 3N / 5N setup and post component QA results please.

@supriyachavan4398
Copy link
Contributor

Created custom build at https://eos-jenkins.colo.seagate.com/job/GitHub-custom-ci-builds/job/generic/job/custom-ci/7809/console
Deployed 6N cluster with the above build at https://eos-jenkins.colo.seagate.com/job/Cortx-Automation/job/RGW/job/setup-cortx-rgw-cluster/12508/console

[root@ssc-vm-g4-rhev4-0710 ~]# kubectl get pods
NAME                             READY   STATUS    RESTARTS   AGE
cortx-consul-client-6w4ss        1/1     Running   0          22m
cortx-consul-client-89ds8        1/1     Running   0          22m
cortx-consul-client-ddv4f        1/1     Running   0          22m
cortx-consul-client-pr8cr        1/1     Running   0          22m
cortx-consul-client-vgmbj        1/1     Running   0          22m
cortx-consul-client-wt28x        1/1     Running   0          22m
cortx-consul-server-0            1/1     Running   0          22m
cortx-consul-server-1            1/1     Running   0          22m
cortx-consul-server-2            1/1     Running   0          22m
cortx-control-56959c679d-7bxtz   1/1     Running   0          22m
cortx-data-g0-0                  3/3     Running   0          22m
cortx-data-g0-1                  3/3     Running   0          22m
cortx-data-g0-2                  3/3     Running   0          22m
cortx-data-g0-3                  3/3     Running   0          22m
cortx-data-g0-4                  3/3     Running   0          22m
cortx-data-g0-5                  3/3     Running   0          22m
cortx-data-g1-0                  3/3     Running   0          22m
cortx-data-g1-1                  3/3     Running   0          22m
cortx-data-g1-2                  3/3     Running   0          22m
cortx-data-g1-3                  3/3     Running   0          22m
cortx-data-g1-4                  3/3     Running   0          22m
cortx-data-g1-5                  3/3     Running   0          22m
cortx-ha-bcb8d7d57-qwnw5         3/3     Running   0          22m
cortx-kafka-0                    1/1     Running   0          22m
cortx-kafka-1                    1/1     Running   0          22m
cortx-kafka-2                    1/1     Running   0          22m
cortx-server-0                   2/2     Running   0          22m
cortx-server-1                   2/2     Running   0          22m
cortx-server-2                   2/2     Running   0          22m
cortx-server-3                   2/2     Running   0          22m
cortx-server-4                   2/2     Running   0          22m
cortx-server-5                   2/2     Running   0          22m
cortx-zookeeper-0                1/1     Running   0          22m
cortx-zookeeper-1                1/1     Running   0          22m
cortx-zookeeper-2                1/1     Running   0          22m
[root@ssc-vm-g4-rhev4-0710 ~]# kubectl exec -it cortx-data-g0-4 -c cortx-hax -- /bin/bash
[root@cortx-data-g0-4 /]# hctl status | grep 'offline|dtm_recovering'
[root@cortx-data-g0-4 /]# hctl status
Bytecount:
    critical : 0
    damaged : 0
    degraded : 0
    healthy : 81708373
Data pool:
    # fid name
    0x6f00000000000001:0x0 'storage-set-1__sns'
Profile:
    # fid name: pool(s)
    0x7000000000000001:0x0 'Profile_the_pool': 'storage-set-1__sns' 'storage-set-1__dix' None
Services:
    cortx-data-g0-0.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x0          inet:tcp:cortx-data-g0-0.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x1          inet:tcp:cortx-data-g0-0.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x2          inet:tcp:cortx-data-g0-0.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g0-1.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x3          inet:tcp:cortx-data-g0-1.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x4          inet:tcp:cortx-data-g0-1.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x5          inet:tcp:cortx-data-g0-1.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-server-4.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x2c         inet:tcp:cortx-server-4.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x2d         inet:tcp:cortx-server-4.cortx-server-headless.cortx.svc.cluster.local@22501
    cortx-server-5.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x2e         inet:tcp:cortx-server-5.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x2f         inet:tcp:cortx-server-5.cortx-server-headless.cortx.svc.cluster.local@22501
    cortx-data-g0-2.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x6          inet:tcp:cortx-data-g0-2.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x7          inet:tcp:cortx-data-g0-2.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x8          inet:tcp:cortx-data-g0-2.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g0-3.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x9          inet:tcp:cortx-data-g0-3.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0xa          inet:tcp:cortx-data-g0-3.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0xb          inet:tcp:cortx-data-g0-3.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g0-4.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0xc          inet:tcp:cortx-data-g0-4.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0xd          inet:tcp:cortx-data-g0-4.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0xe          inet:tcp:cortx-data-g0-4.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g0-5.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0xf          inet:tcp:cortx-data-g0-5.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x10         inet:tcp:cortx-data-g0-5.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x11         inet:tcp:cortx-data-g0-5.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-0.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x12         inet:tcp:cortx-data-g1-0.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x13         inet:tcp:cortx-data-g1-0.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x14         inet:tcp:cortx-data-g1-0.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-1.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x15         inet:tcp:cortx-data-g1-1.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x16         inet:tcp:cortx-data-g1-1.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x17         inet:tcp:cortx-data-g1-1.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-2.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x18         inet:tcp:cortx-data-g1-2.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x19         inet:tcp:cortx-data-g1-2.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x1a         inet:tcp:cortx-data-g1-2.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-3.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x1b         inet:tcp:cortx-data-g1-3.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x1c         inet:tcp:cortx-data-g1-3.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x1d         inet:tcp:cortx-data-g1-3.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-4.cortx-data-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x1e         inet:tcp:cortx-data-g1-4.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x1f         inet:tcp:cortx-data-g1-4.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x20         inet:tcp:cortx-data-g1-4.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-data-g1-5.cortx-data-headless.cortx.svc.cluster.local  (RC)
    [started]  hax                 0x7200000000000001:0x21         inet:tcp:cortx-data-g1-5.cortx-data-headless.cortx.svc.cluster.local@22001
    [started]  ioservice           0x7200000000000001:0x22         inet:tcp:cortx-data-g1-5.cortx-data-headless.cortx.svc.cluster.local@21002
    [started]  confd               0x7200000000000001:0x23         inet:tcp:cortx-data-g1-5.cortx-data-headless.cortx.svc.cluster.local@21001
    cortx-server-0.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x24         inet:tcp:cortx-server-0.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x25         inet:tcp:cortx-server-0.cortx-server-headless.cortx.svc.cluster.local@22501
    cortx-server-1.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x26         inet:tcp:cortx-server-1.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x27         inet:tcp:cortx-server-1.cortx-server-headless.cortx.svc.cluster.local@22501
    cortx-server-2.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x28         inet:tcp:cortx-server-2.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x29         inet:tcp:cortx-server-2.cortx-server-headless.cortx.svc.cluster.local@22501
    cortx-server-3.cortx-server-headless.cortx.svc.cluster.local
    [started]  hax                 0x7200000000000001:0x2a         inet:tcp:cortx-server-3.cortx-server-headless.cortx.svc.cluster.local@22001
    [started]  rgw_s3              0x7200000000000001:0x2b         inet:tcp:cortx-server-3.cortx-server-headless.cortx.svc.cluster.local@22501
[root@cortx-data-g0-4 /]#

cc. @d-nayak, @vaibhavparatwar

@d-nayak d-nayak merged commit dd4b842 into Seagate:main Sep 12, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants