what data is removed during DEFRAG

91 views
Skip to first unread message

Rinse Lemstra

unread,
Jun 3, 2024, 5:32:12 AMJun 3
to H2 Database

My databases (mvstore) are growing rapidly, much more than I would expect based on the entered data. I also see CPU usage increasing.

Performing a DEFRAG reduces the database size significantly, sometimes by 60-70%. Running SCRIPT TO / RUNSCRIPT also has a similar effect.

How can I identify what 'pollution' is consuming so much space? Browsing through the INFORMATION_SCHEMA has not provided any clues.

We recently started using "CREATE MEMORY LOCAL TEMPORARY TABLE IF NOT EXISTS" more frequently. Could this be related to the problem?

Andrei Tokar

unread,
Jun 8, 2024, 5:20:34 PMJun 8
to H2 Database

Plaese see nice recent message here. I hope it will help to manage your expectations about database file size.

Yusuf Welder

unread,
Jun 9, 2024, 11:31:09 AMJun 9
to H2 Database
Reply all
Reply to author
Forward
0 new messages