se7enxweb / owdatabasecheckup
Checkup and maintenance command-line scripts to fix common inconsistencies in eZ Publish database
Package info
github.com/se7enxweb/OWDatabaseCheckup
Type:exponential-extension
pkg:composer/se7enxweb/owdatabasecheckup
Fund package maintenance!
Requires
- php: >=8.0
- se7enxweb/exponential-legacy-installer: ^2.2.6
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-12-03 18:37:13 UTC
README
Extension : OWDatabaseCheckup v0.1
Requires : eZ Publish 4.x and 5.x
Author : Open Wide http://www.openwide.fr
What is OWDatabaseCheckup ?
OWDatabaseCheckup provides php cli scripts for common database maintenance.
fixcontentobjectattributes.php
Removing a class attribute should also remove all corresponding object attributes. If it doesn't for any reason, object attributes remain orphans in ezcontentobject_attribute table and may cause fatal errors.
This script gets all orphans object attributes and remove them from ezcontentobject_attribute table.
php bin/php/fixcontentobjectattributes.php [--dry-run] [--remove-objectattributes]
--dry-runoption : displays the missing class attributes IDs and the total number of orphan content attributes--remove-objectattributesoption : removes all orphan content attributes
fixobjectswithoutmainnode.php
Content objects are always published with at least one main node. Sometimes, using the API to create content can lead to published objects with no nodes.
This scripts gets all published content objects which do not have any nodes avoiding in trash objects and drafts. Then you can add a new main node or delete them.
php bin/php/fixobjectswithoutmainnode.php [--dry-run] [--update-objects] [--target-node=VALUE] [--remove-objects]
--dry-runoption : displays the IDs and the total number of published content objects which do not have any nodes--update-objectsoption : adds a new main node to these content objects--target-node=VALUEoption : use it with--update-objectsoption to specifiy the parent node ID of the new main nodes--remove-objectsoption : removes content objects which do not have any nodes
CAUTION
These scripts directly modifies your eZ Publish database records. You shall back it up before running them !
What's coming next ?
- Other database inconsistencies may occure. New scripts should be added in the future.
- Back-office interface to run checkups
Official status: Officially Approved for Exponential 6.