Bug #114802 | "missing table" in MySQL NDB cluster | ||
---|---|---|---|
Submitted: | 27 Apr 2024 9:07 | Modified: | 7 May 2024 11:56 |
Reporter: | CunDi Fang | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Cluster: Cluster (NDB) storage engine | Severity: | S2 (Serious) |
Version: | 8.0.35-cluster MySQL Cluster Community S | OS: | Any (20.04) |
Assigned to: | MySQL Verification Team | CPU Architecture: | Any |
[27 Apr 2024 9:07]
CunDi Fang
[29 Apr 2024 23:12]
MySQL Verification Team
Hi, I cannot reproduce this issue and from looking at log files looks like network issues?
[30 Apr 2024 2:48]
CunDi Fang
很奇怪,我在我这边的环境上成功复现了这个bug。不过确实发现这个bug对于时间的要求很严格,您需要严格控制让UPDATE语句的注入时间是在两个ALTER TABLE语句都正在执行的时候。我可以把我的时间图给你。
[30 Apr 2024 2:49]
CunDi Fang
I have successfully reproduced this bug on my side of the environment. but did find that the bug is very strict about timing, and you need to be strict about letting the UPDATE statement be injected at a time when both ALTER TABLE statements are executing. I can give you my timing chart.
[30 Apr 2024 2:50]
CunDi Fang
This is the time diagram, the blue is the update statement, the green and red are the two alter statements.
Attachment: Figure_2.png (image/png, text), 23.65 KiB.
[30 Apr 2024 6:45]
CunDi Fang
As you can see below, in my environment, after three attempts, the "missing table" issue occurs once ``` root@c52726a7c962 /h/m/v/n/build# ./node-repeat-main MySQL connection established prepare to read SQL executed successfully. num: 280000 start time: 1714458874.280194 end time:1714458874.719622 root@c52726a7c962 /h/m/v/n/build# mysql -uroot -proot mytest90 < /home/mine-code/mysqlerror_0/28-5-6-2-database90.sql mysql: [Warning] Using a password on the command line interface can be insecure. root@c52726a7c962 /h/m/v/n/build# ./node-repeat-main MySQL connection established prepare to read SQL executed successfully. num: 280000 start time: 1714458910.280161 end time:1714458910.284287 root@c52726a7c962 /h/m/v/n/build# mysql -uroot -proot mytest90 < /home/mine-code/mysqlerror_0/28-5-6-2-database90.sql mysql: [Warning] Using a password on the command line interface can be insecure. root@c52726a7c962 /h/m/v/n/build# ./node-repeat-main MySQL connection established prepare to read MySQL query failed: Table 'mytest90.test8' doesn't exist num: 280000 start time: 1714458944.280185 end time:1714458944.288990 ``` However, I've found that the issue doesn't manifest itself in the log file, and it seems that I need to turn on specific logging configurations in order to generate a log that can record these statements, and I don't see the expected results in the binary logs. I will provide the DATA file I used to reproduce it and hopefully it will help you with the reproduction.
[30 Apr 2024 13:33]
MySQL Verification Team
Hi, Log file did not upload correctly so I cannot open it, can you please upload the same file again thanks
[30 Apr 2024 15:28]
MySQL Verification Team
Yes, this one is good
[7 May 2024 7:39]
MySQL Verification Team
I do not see a problem in your logs and I cannot reproduce behavior that I would consider a bug.
[7 May 2024 11:56]
CunDi Fang
I got the log file directly from the "ndb_error_reporter /var/lib/mysql-cluster/config.ini root" command, and I'm also wondering why this error is not reflected in the log file. But I did reproduce the problem by sending the exact sql statements. Can you just try to enter the sql statements directly on the node as I described? According to my reproduction attempts on my machine, it is reproducible. Or please let me know if I need to open some log related configuration to get more and more detailed log files?