Hubzilla
Login
Hubzilla
Login
System Apps
Directory
Help
Language
Public Stream
Random Channel
Report Bug
Search
2025-02-11 11:48:24
View Profile
Hubzilla Support Forum
adminsforum@hubzilla.org
Hiker
wrote the following
post
Tue, 11 Feb 2025 11:48:34 +0100
Are there any tools to maintain the database? It is getting bigger and bigger...
3
Der Pepe (Hubzilla) ⁂ ⚝
Alfred Bühler
Alexander Goeres
Link to Source
show all
6 comments
2025-02-11 12:28:14
View Profile
Scott M. Stolz
scott@loves.tech
Does "Expiration period in days for imported (grid/network) content" in /admin/site do what I think it does? Does it delete imported posts older than
x
number of days?
If so, that might be a useful setting.
1
Der Pepe (Hubzilla) ⁂ ⚝
Link to Source
2025-02-11 12:44:15
View Profile
Der Pepe (Hubzilla) ⁂ ⚝
pepecyb@hub.hubzilla.hu
@
Hiker
@
Scott M. Stolz
For example, I entered 14 days there (because older imported (!) Posts are rarely accessed anyway) and I have a fairly stable database size, which now mainly only grows with my own content and that of the users of my hub.
2
Scott M. Stolz
Alfred Bühler
Link to Source
2025-02-11 13:12:30
View Profile
Harald Eilertsen
harald@hub.volse.no
@
Hiker
Which DB engine? Note that databases will normally not shrink their storage even when purging records, but they provide tools for reclaiming storage (essentially copying the data to new files, but without the gaps in the original data files.) See the docs for your database for how to do that.
1
Scott M. Stolz
Link to Source
2025-02-11 13:31:09
View Profile
Mark Nowiasz
buckaroo@hub.netzgemeinde.eu
If you use MySQL (including all the different flavours, like mariadb, percona, whatever) you can try running
mysqloptimize -v -A
. This is a safe operation, the database won't go offline. But it could take some time, I usually do this once a week, and it takes at my site (140 GB DB) about 1h, so it's wise running it in a tmux/screen session. But you need some addtional disk space to perform this, so if you are very low on disk space this might not work.
3
Harald Eilertsen
Alexander Goeres
Scott M. Stolz
Link to Source
2025-02-11 19:28:58
View Profile
Hiker
hiker@fedhub.ch
I thought that Hubzilla has own tools to optimize the database - how long eg posts are store before deleted.
Link to Source
2025-02-11 19:36:41
View Profile
Harald Eilertsen
harald@hub.volse.no
@
Hiker
Those are two different things. Hubzilla will delete items that have not been interacted with after a certain (configurable) time. However, that may not reclaim the space used by the database. The database handles it's resources and how much storage space it needs.
Link to Source
Conversation Features
Loading...
Conversation Features
Loading...
Login
Email or nickname
Password
Remember me
Login
Register
Password Reset
Remote Authentication