monogo / optimizedatabase
Magento 2 module for optimization of database fragmentation.
Installs: 12 434
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 3
Forks: 0
Open Issues: 0
Type:magento2-module
Requires
- php: ~7.3.0||~7.4.0
- magento/framework: *
- magento/magento-composer-installer: *
- phplucidframe/console-table: ^1.2
- symfony/console: *
This package is auto-updated.
Last update: 2024-10-29 05:34:28 UTC
README
Magento 2 module for optimization of database fragmentation.
Install
Git
- Locate the /app/code directory which should be under the magento root installation.
- If the code folder is not there, create it.
- Create a folder Monogo inside the code folder.
- Change to the Monogo folder and clone the Git repository (https://github.com/MonogoPolska/monogo-m2-optimize-database.git) into Monogo specifying the local repository folder to be OptimizeDatabase e.g.
git clone https://github.com/MonogoPolska/monogo-m2-optimize-database.git OptimizeDatabase
Composer
composer require monogo/optimizedatabase
Magento Setup
- Run Magento commands
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy
App Configuration Options
Go to Stores->Configuration->Monogo->Optimize database
- Enable module Default value is 1 (Yes)
- Minimal fragmentation ratio - Optimize tables for which fragmentation ratio is higher than this value. Default value is 1
- Use Magento Cron - You can disable Magento cron and run Optimization from shell Default value is 0 (No)
- Cron schedule - Use Crontab Format (Eg. "05 1 * * *" every day at 01:05)
Default values:
Shell
Usage: php bin/magento monogo:optimize:database [--mode MODE]
print Print all tables
optimize Optimize tables
help This help
for example:
php bin/magento monogo:optimize:database --mode print
Possible output:
Module is disabled in Stores->Configuration->Monogo->Optimize database