Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reef: common: counter dump command revision #52469

Merged
merged 2 commits into from
Jul 19, 2023
Merged

Conversation

idryomov
Copy link
Contributor

alimaredia and others added 2 commits July 15, 2023 10:02
`counter dump` now emits an array of
<labels,counters> pairs for each individual key.

Commit includes revisions to perf counters unit
test.

Fixes: https://tracker.ceph.com/issues/61587
Signed-off-by: Ali Maredia <amaredia@redhat.com>
(cherry picked from commit 78a1488)
Adopt the counter dump format changes in exporter for extracting the counters.
Removed the condition for `PERFCOUNTER_TIME` as counter dump already does
tranformation internally.

Signed-off-by: Avan Thakkar <athakkar@redhat.com>
(cherry picked from commit 3e8ef70)
@idryomov idryomov requested a review from a team as a code owner July 15, 2023 08:06
@idryomov idryomov added this to the reef milestone Jul 15, 2023
@idryomov idryomov requested review from alimaredia, avanthakkar and a team July 15, 2023 08:10
@idryomov
Copy link
Contributor Author

@avanthakkar Please repeat the metrics endpoint test with two RBD images here and post the results.

@alimaredia
Copy link
Contributor

@avanthakkar do you have the metrics endpoint test with two RBD images here and post the results yet?

@yuriw yuriw merged commit 7dd5a73 into ceph:reef Jul 19, 2023
10 of 11 checks passed
@idryomov idryomov deleted the wip-61587-reef branch July 19, 2023 16:05
@idryomov
Copy link
Contributor Author

@avanthakkar do you have the metrics endpoint test with two RBD images here and post the results yet?

@avanthakkar This got merged but I would still like you to produce the dumps and post them here.

@avanthakkar
Copy link
Contributor

@avanthakkar do you have the metrics endpoint test with two RBD images here and post the results yet?

@avanthakkar This got merged but I would still like you to produce the dumps and post them here.

Sorry I've been busy with other priority tasks. I've started the build now, will paste the output for dumps and metrics once build is ready!

@avanthakkar
Copy link
Contributor

avanthakkar commented Jul 24, 2023

@avanthakkar do you have the metrics endpoint test with two RBD images here and post the results yet?

@avanthakkar This got merged but I would still like you to produce the dumps and post them here.

Sorry I've been busy with other priority tasks. I've started the build now, will paste the output for dumps and metrics once build is ready!

I tried to do build locally on reef but it fails for me while starting mstart cluster.

2023-07-24T13:20:02.035+0530 7f23f7a12580 -1 can't open site-a.conf: (2) No such file or directory
2023-07-24T13:20:02.035+0530 7f23f7a12580 -1 Errors while parsing config file!
2023-07-24T13:20:02.035+0530 7f23f7a12580 -1 can't open site-a.conf: (2) No such file or directory
unable to get monitor info from DNS SRV with service name: ceph-mon
2023-07-24T13:20:02.036+0530 7f23f7a12580 -1 failed for service _ceph-mon._tcp
rbd: couldn't connect to the cluster!
2023-07-24T13:20:02.036+0530 7f23f7a12580 -1 monclient: get_monmap_and_config cannot identify monitors to contact
did not load config file, using default settings.
2023-07-24T13:20:02.074+0530 7fa08dff1580 -1 Errors while parsing config file!
2023-07-24T13:20:02.074+0530 7fa08dff1580 -1 can't open site-a.conf: (2) No such file or directory
2023-07-24T13:20:02.074+0530 7fa08dff1580 -1 Errors while parsing config file!
2023-07-24T13:20:02.074+0530 7fa08dff1580 -1 can't open site-a.conf: (2) No such file or directory
unable to get monitor info from DNS SRV with service name: ceph-mon
2023-07-24T13:20:02.075+0530 7fa08dff1580 -1 failed for service _ceph-mon._tcp
2023-07-24T13:20:02.075+0530 7fa08dff1580 -1 monclient: get_monmap_and_config cannot identify monitors to contact
rbd: couldn't connect to the cluster!

This the script i use to setup rbd-mirror https://paste.sh/EqKoidUt#dwz97kAPkfZ0Djmh6wpO6iYm

@idryomov
Copy link
Contributor Author

It looks like site-a.conf and site-b.conf files are missing? They need to be present in the directory you are running bin/rbd-mirror --cluster site-a and other commands from.

@weirdwiz
Copy link
Contributor

weirdwiz commented Aug 7, 2023

I ran the rbd-mirror daemon on reef, and here's the counter and ceph-exporter dump:

    "rbd_mirror_snapshot_image": [
        {
            "labels": {
                "image": "image1",
                "namespace": "",
                "pool": "data"
            },
            "counters": {
                "snapshots": 1,
                "sync_time": {
                    "avgcount": 1,
                    "sum": 4.418287199,
                    "avgtime": 4.418287199
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691403499.591300109,
                "local_timestamp": 1691403499.591300109,
                "last_sync_time": 4.418287199,
                "last_sync_bytes": 524288000
            }
        },
        {
            "labels": {
                "image": "image2",
                "namespace": "",
                "pool": "data"
            },
            "counters": {
                "snapshots": 1,
                "sync_time": {
                    "avgcount": 1,
                    "sum": 6.176838533,
                    "avgtime": 6.176838533
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691403728.669556493,
                "local_timestamp": 1691403728.669556493,
                "last_sync_time": 6.176838533,
                "last_sync_bytes": 524288000
            }
        },
        {
            "labels": {
                "image": "image2",
                "namespace": "testing",
                "pool": "data"
            },
            "counters": {
                "snapshots": 1,
                "sync_time": {
                    "avgcount": 1,
                    "sum": 6.078289046,
                    "avgtime": 6.078289046
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691403507.484206508,
                "local_timestamp": 1691403507.484206508,
                "last_sync_time": 6.078289046,
                "last_sync_bytes": 524288000
            }
        }
    ],

https://paste.sh/rtiHgbrw#3VaEwxaP96QplAefPTHQ_ii-

@idryomov
Copy link
Contributor Author

idryomov commented Aug 7, 2023

@weirdwiz The posted counter dump output doesn't match what is in the paste at all. Wrong link?

@weirdwiz
Copy link
Contributor

weirdwiz commented Aug 7, 2023

i think there were more snapshots taken on schedule when i was capturing the output to paste it here. let me run it again and remove the schedule

@weirdwiz
Copy link
Contributor

weirdwiz commented Aug 7, 2023

updated output:

    "rbd_mirror_snapshot_image": [
        {
            "labels": {
                "image": "image1",
                "namespace": "",
                "pool": "data"
            },
            "counters": {
                "snapshots": 1,
                "sync_time": {
                    "avgcount": 1,
                    "sum": 4.889262373,
                    "avgtime": 4.889262373
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691406763.567461918,
                "local_timestamp": 1691406763.567461918,
                "last_sync_time": 4.889262373,
                "last_sync_bytes": 524288000
            }
        },
        {
            "labels": {
                "image": "image2",
                "namespace": "",
                "pool": "data"
            },
            "counters": {
                "snapshots": 2,
                "sync_time": {
                    "avgcount": 2,
                    "sum": 5.565792467,
                    "avgtime": 2.782896233
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691406898.801305766,
                "local_timestamp": 1691406898.801305766,
                "last_sync_time": 0.003495392,
                "last_sync_bytes": 0
            }
        },
        {
            "labels": {
                "image": "image2",
                "namespace": "testing",
                "pool": "data"
            },
            "counters": {
                "snapshots": 2,
                "sync_time": {
                    "avgcount": 2,
                    "sum": 4.896217627,
                    "avgtime": 2.448108813
                },
                "sync_bytes": 524288000,
                "remote_timestamp": 1691406832.619604003,
                "local_timestamp": 1691406832.619604003,
                "last_sync_time": 0.003299133,
                "last_sync_bytes": 0
            }
        }
    ],

https://paste.sh/rtiHgbrw#3VaEwxaP96QplAefPTHQ_ii-

@idryomov
Copy link
Contributor Author

idryomov commented Aug 7, 2023

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants