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

PD store usage not right in master. #4906

Closed
jiaqizho opened this issue May 17, 2022 · 0 comments · Fixed by #4907
Closed

PD store usage not right in master. #4906

jiaqizho opened this issue May 17, 2022 · 0 comments · Fixed by #4907
Assignees
Labels
feature/developing severity/minor type/bug The issue is confirmed as a bug.

Comments

@jiaqizho
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

  • The tiflash used from tiflash metrics

image

  • The metrics from pd

image

They both called getFsStats(). And but get the different result.
I think the problem in pd.rs handle_store_heartbeat:

let capacity = store_stats.fs_stats.capacity_size;
        let available = store_stats.fs_stats.avail_size;
        stats.set_used_size(store_stats.fs_stats.used_size);
        stats.set_capacity(capacity);

        let used_size = self.snap_mgr.get_total_snap_size().unwrap()
            + store_info
                .kv_engine
                .get_engine_used_size()
                .expect("kv engine used size")
            + store_info
                .raft_engine
                .get_engine_size()
                .expect("raft engine used size");
        stats.set_used_size(used_size);

The below set_used_size replace the origin one.

2. What did you expect to see? (Required)

3. What did you see instead (Required)

4. What is your TiFlash version? (Required)

@jiaqizho jiaqizho added the type/bug The issue is confirmed as a bug. label May 17, 2022
This was referenced May 17, 2022
@CalvinNeo CalvinNeo removed the type/bug The issue is confirmed as a bug. label May 17, 2022
@lidezhu lidezhu added type/bug The issue is confirmed as a bug. feature/developing severity/minor labels May 17, 2022
ti-chi-bot pushed a commit that referenced this issue May 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature/developing severity/minor type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants