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

call dolt_stats_restart() executed using dolt sql -q in the root of the database puts stats in the wrong place #8324

Closed
timsehn opened this issue Sep 4, 2024 · 1 comment · Fixed by #8334
Labels
bug Something isn't working performance sql Issue with SQL

Comments

@timsehn
Copy link
Contributor

timsehn commented Sep 4, 2024

$ du -h                                               
4.0K	./.doltcfg
479G	./.dolt/noms/oldgen
479G	./.dolt/noms
  0B	./.dolt/temptf
  0B	./.dolt/stats/.dolt/noms/oldgen
1.0M	./.dolt/stats/.dolt/noms
  0B	./.dolt/stats/.dolt/temptf
1.0M	./.dolt/stats/.dolt
1.0M	./.dolt/stats
479G	./.dolt
654G	.
$ dolt sql -q "call dolt_stats_restart()"
+----------------------------------------------+
| message                                      |
+----------------------------------------------+
| restarted stats collection: refs/statistics/ |
+----------------------------------------------+
$ du -h                                  
  0B	./media_wiki/.dolt/stats/.dolt/noms/oldgen
1.0M	./media_wiki/.dolt/stats/.dolt/noms
  0B	./media_wiki/.dolt/stats/.dolt/temptf
1.0M	./media_wiki/.dolt/stats/.dolt
1.0M	./media_wiki/.dolt/stats
1.0M	./media_wiki/.dolt
1.0M	./media_wiki
4.0K	./.doltcfg
479G	./.dolt/noms/oldgen
479G	./.dolt/noms
  0B	./.dolt/temptf
  0B	./.dolt/stats/.dolt/noms/oldgen
1.0M	./.dolt/stats/.dolt/noms
  0B	./.dolt/stats/.dolt/temptf
1.0M	./.dolt/stats/.dolt
1.0M	./.dolt/stats
479G	./.dolt
654G	.

Notice how it makes a new media_wiki directory. The stats are not in the .dolt directory they refer to.

@timsehn
Copy link
Contributor Author

timsehn commented Sep 4, 2024

Note, the database continues to use the stats in the wrong location as long as the database server has not been restarted. But, it seems it cannot find these stats on restart.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working performance sql Issue with SQL
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant