Topic on Project:Support desk

The volume of the _text table increases abnormally

9
Zer00CooL (talkcontribs)

If i export all page from special page, all my content = 10 Mo

If i look in the database, the table _text = 280 Mo !


It would be absolutely necessary to propose a solution, to clean the table _text properly, and, to allow to keep only the last global version of the page.


My post : https://phabricator.wikimedia.org/T239104

My answer : Manual talk:Text table


In my case, indeed, only the latest version from a page interests me.


So I'm in a special case, since, a wiki must be used to keep the history.


Despite everything, this methodology is very heavy, for the database, and, the system resources.

In my case, I wish to be able to use the latest version, since it is a personal summary for the pages I write.


The versioning is practical, during the writing, but, I wish to be able to launch every day, a script which cleans the base, to only offer an optimized version, and, I then delete the revisions.


Currently, I do so:

maintenance/deleteOldRevisions.php --delete

maintenance/rebuildrecentchanges.php

maintenance/deleteArchivedRevisions.php --delete

maintenance/deleteAutoPatrolLogs.php

maintenance/rebuildall.php

Bawolff (talkcontribs)

you may also want $wgCompressRevisions.


See docs for cron for your operating system. https://man7.org/linux/man-pages/man5/crontab.5.html

Probably rebuildall and rebuildrecentchanges arent needed since rebuildrecentchanges is a subset of rebuildall, and more generally i am unsure if its needed at all.

Depending on your db, you may want to optimize the underlying table.

This post was hidden by Zer00CooL (history)
Zer00CooL (talkcontribs)

Yes i have, for example :

ALTER TABLE prefixe_text ROW_FORMAT=COMPRESSED;

ALTER TABLE prefixe_externallinks ROW_FORMAT=COMPRESSED;

ALTER TABLE prefixe_searchindex ROW_FORMAT=COMPRESSED;


The table is correctly compressed, but, when i download the sql, i have always 500Mo.

It's not the good way, for me. I search a better solution.


Debian Buster Stable.

My DB is MariaDB, innodb, utf8-mb4

Mediawiki 1.33.3


Conf for mariadb :

[mariadb-10.3]

innodb_file_format = Barracuda

innodb_file_per_table = 1

innodb_default_row_format = dynamic

innodb_large_prefix = 1

Bawolff (talkcontribs)
This post was hidden by Zer00CooL (history)
Zer00CooL (talkcontribs)

No,

OPTIMIZE is a MySQL command for OPTIMIZE.

I don't want OPTIMIZE, i want clear all old content.

If all my page = 10 Mo from special page export it's not normal all my page = 400 Mo in the table _text

In my case, i want only the last revision, and, clear all old history, and, content.

Zer00CooL (talkcontribs)

I read the same requests, with people having databases of 2 ... 8 ... Go

It's a lot, for me, and, I think that everyone does not necessarily need to keep the history. At a given moment, it is necessary to clean the base, to allow its export, its backup, its redeployment.

In my opinion, it is urgent to bring a possibility to the cleaning of the table _text.

Otherwise, it forces you to export the pages to XML, and reinstall them on a new wiki. It's tedious.

Bawolff (talkcontribs)

in certain configs mysql wont actually delete things (release space back to the hard drive) until you run optimize, which is why i suggested it.

Reply to "The volume of the _text table increases abnormally"