-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
RethinkDB shuts down slowly on rotational drive #1547
Comments
This indicates that the disk is actually saturated by the server. If this is indeed the garbage collector:
Another interesting effect is that memory utilization as reported by htop fluctuates significantly during the shutdown process. It varied between about 30% (of 6 GB total on this machine), and up to more than 67%, repeatedly going up and down. I wouldn't expect memory consumption to increase (that much) during shutdown. |
I don't think it's necessarily clear that it's GC that causes a slow shutdown and isn't being interrupted. We need to validate that theory first. |
If I may ask did you shutdown immediately after writing all this data? Also how much memory does the server have its self? What sort of write durability was used for inserting the data? |
Hi @wojons , I shut it down relatively shortly after writing the data, which I inserted with soft durability. |
@danielmewes So far in all of my tests I have had fast shut downs on spinning disk (Less then 30 seconds). I have seen your issue with other databases. Did you have any extra indexes other then the primary? |
@wojons Thanks for chiming in. I did not have any secondary indexes. I will check later which exact circumstances are required to reproduce it. |
@danielmewes i think i just ran into your problem i did a mass delete of 2 million items and the shutdown took a while |
Closing as outdated. |
@danielmewes do we want to test this before closing it. |
If this was happening in debug mode, it may have been due to some debug checks that were performed. I ran into that a couple months ago and removed the check as it was rather antiquated. If this was happening in release mode, nevermind. |
@Tryneus i can find sometime this weekened to load 2M real records into a spinning disk db and then delete it and then shutdown and see if its still happending if @danielmewes he can assign it to me. |
Yeah I closed this because the last instance I'm aware of at least was quite a while ago and we changed and fixed a lot of things since. Please just re-open this if you see it again. |
Just something I've noticed which might be worth investigating:
After inserting a lot of data (~100 GB) into a single RethinkDB instance on rotational drives, I shut down the server. There was only one table, with a cache size of just 1 GB. After about 15 minutes, it is still shutting down.
What's weird is the output of
iostat -m
:First of all the write throughput is extremely low at less than a MB per second. Interestingly, RethinkDB is reading more data than writing. I assume this is the garbage collector at work.
At the same time, the relatively high number of transactions (305 on sda) could indicate that it is bound by disk seeks but that's just speculation.
The server uses only very little CPU at this point.
The text was updated successfully, but these errors were encountered: