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

IndexLookUpExecutor use too many memory and can't be killed. #56440

Closed
wshwsh12 opened this issue Oct 3, 2024 · 1 comment · Fixed by #56497
Closed

IndexLookUpExecutor use too many memory and can't be killed. #56440

wshwsh12 opened this issue Oct 3, 2024 · 1 comment · Fixed by #56497
Labels
affects-5.4 This bug affects the 5.4.x(LTS) versions. affects-6.1 This bug affects the 6.1.x(LTS) versions. affects-6.5 This bug affects the 6.5.x(LTS) versions. affects-7.1 This bug affects the 7.1.x(LTS) versions. affects-7.5 This bug affects the 7.5.x(LTS) versions. affects-8.1 This bug affects the 8.1.x(LTS) versions. severity/major sig/execution SIG execution type/bug The issue is confirmed as a bug.

Comments

@wshwsh12
Copy link
Contributor

wshwsh12 commented Oct 3, 2024

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

image image

During the index look up range construction, the memory tracker and killsignal were not properly passed into the function, causing memory to be untraceable.

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

3. What did you see instead (Required)

4. What is your TiDB version? (Required)

master, v8.3.0

@wshwsh12
Copy link
Contributor Author

wshwsh12 commented Oct 3, 2024

Reproduced Step:

  1. Build data 8000000 rows.
    create table t2(a int, b int, c int, index idx(b)) partition by hash(a) partitions 100;
    insert into values from 1-8000000
  2. Run sql. desc analyze select /*+ inl_hash_join(t1) */ * from t2 t1 join t2 t2 on t1.b=t2.b; and wait 60s.
  3. Get heap profile.
image
  1. Cancel the sql and show the slow log. The sql only trace 50MB.
image

@wshwsh12 wshwsh12 added affects-6.1 This bug affects the 6.1.x(LTS) versions. affects-6.5 This bug affects the 6.5.x(LTS) versions. affects-7.1 This bug affects the 7.1.x(LTS) versions. affects-7.5 This bug affects the 7.5.x(LTS) versions. affects-8.1 This bug affects the 8.1.x(LTS) versions. labels Oct 9, 2024
@wshwsh12 wshwsh12 added the affects-5.4 This bug affects the 5.4.x(LTS) versions. label Oct 9, 2024
@ti-chi-bot ti-chi-bot bot removed the may-affects-5.4 This bug maybe affects 5.4.x versions. label Oct 9, 2024
@ti-chi-bot ti-chi-bot bot closed this as completed in 5b44864 Oct 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects-5.4 This bug affects the 5.4.x(LTS) versions. affects-6.1 This bug affects the 6.1.x(LTS) versions. affects-6.5 This bug affects the 6.5.x(LTS) versions. affects-7.1 This bug affects the 7.1.x(LTS) versions. affects-7.5 This bug affects the 7.5.x(LTS) versions. affects-8.1 This bug affects the 8.1.x(LTS) versions. severity/major sig/execution SIG execution type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants