Download the PHP package aksoyhlc/databasebackup without Composer
On this page you can find all versions of the php package aksoyhlc/databasebackup. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download aksoyhlc/databasebackup
More information about aksoyhlc/databasebackup
Files in aksoyhlc/databasebackup
Package databasebackup
Short Description Advanced backup system for MySQL and MariaDB databases. This package allows you to easily backup, list, download, delete, and upload databases to FTP without using `mysqldump`.
License GPL-3.0-or-later
Informations about the package databasebackup
Database Backup
Backup system for MySQL and MariaDB databases. Create, list, download, delete, and upload backups to FTP without mysqldump.
Why Use This Package
Safe and Reliable
- No shell_exec or exec required (mysqldump needs these)
- PHP-based, no system command execution
- Works under hosting provider restrictions
Use Cases
- Shared hosting without mysqldump access
- VPS and cloud servers
- Automated backup systems
- Web-based backup interfaces
Key Features
- No mysqldump dependency
- Full database backup without shell commands
- Selective backup (exclude tables, structure-only, data-only)
- Optional compression and FTP upload
- Debug logging and progress tracking
Security
- No system command execution risk
- Compatible with hosting security rules
- SSL/TLS for FTP connections
Features
- Full database backup (tables, views, triggers, stored procedures)
- Exclude specific tables or backup only structure or data
- Gzip compression
- Auto-cleanup by count or age
- FTP/FTPS upload (automatic or manual)
- Progress callback
- Logging
Installation
Basic Usage
Advanced Usage
Performance
DatabaseBackup uses streaming architecture and unbuffered queries to handle databases of any size with minimal resource usage. No mysqldump dependency required.
Benchmarks (1,050,000 records, 7 tables)
| Mode | File Size | Duration |
|---|---|---|
| Uncompressed | 1.33 GB | 17.0 s |
| Gzip compressed | 314 MB | 57.5 s |
Benchmark (Employees DB: 3,920,015 records, 6 tables + 2 views)
| Mode | File Size | Duration |
|---|---|---|
| Gzip compressed | 33.7 MB | 46.6 s |
vs mysqldump (1,050,000 records)
| Tool | File Size | Duration |
|---|---|---|
| DatabaseBackup (stream) | 1.33 GB | 17.0 s |
mysqldump |
1.30 GB | 11.8 s |
| DatabaseBackup (gzip) | 314 MB | 57.5 s |
mysqldump + gzip (pipe) |
314 MB | 31.1 s |
Key Performance Features
- Streaming writes: SQL goes directly to disk, not accumulated in memory.
- Unbuffered queries: One row at a time, no result set buffering.
- Configurable batch size: Tune
batchSizefor INSERT performance.
Special Characters
UTF-8 characters, emoji, JSON, BLOB, backslash, and multi-line text are preserved during backup and restore.
Tested with: ๐๐ฅ๐๐ฏโ
, ๐จโ๐ฉโ๐งโ๐ฆ, JSON, BLOB, multi-line text, O'Brien, C:\Users\path, null values.
Log Messages
Connection Tests
Configuration Parameters
Database Configuration ($dbConfig)
| Parameter | Description | Default |
|---|---|---|
host |
Database server address | 'localhost' |
dbname |
Database name | - |
user |
Database username | - |
pass |
Database password | - |
charset |
Database character set | 'utf8mb4' |
port |
Database server port number | 3306 |
General Configuration Options ($options)
Cache Settings
| Parameter | Description | Default |
|---|---|---|
cacheTime |
Cache duration (seconds) | 3600 |
Backup File Cleanup Settings
| Parameter | Description | Default |
|---|---|---|
maxBackupCount |
Maximum number of backups to keep | 10 |
maxBackupAgeDays |
Maximum backup age to keep (days) | 365 |
Content Filtering Settings
| Parameter | Description | Default |
|---|---|---|
excludedTables |
Array of table names to exclude from backup | [] |
tableModes |
Table backup modes ('full', 'structure_only', 'data_only') |
[] |
Backup Format Settings
| Parameter | Description | Default |
|---|---|---|
compressOutput |
Compress the backup file? (gzip) | false |
removeDefiners |
Remove SQL DEFINER statements? | true |
batchSize |
Number of rows per INSERT statement | 100 |
Progress Tracking
| Parameter | Description | Default |
|---|---|---|
progressCallback |
Progress status notification function function($status, $current, $total) |
null |
FTP Configuration (ftpConfig)
| Parameter | Description | Default |
|---|---|---|
enabled |
Is FTP backup active? | false |
host |
FTP server address | '' |
username |
FTP username | '' |
password |
FTP password | '' |
port |
FTP port number | 21 |
path |
Remote directory path | '/' |
ssl |
Use SSL? | false |
passive |
Use passive mode? | true |
Requirements
- PHP 7.4 or higher
- PDO PHP Extension
- MySQL or MariaDB database
- For FTP operations: FTP PHP Extension
- For compression: Zlib PHP Extension
License
This project is open-sourced software licensed under the GPL license
All versions of databasebackup with dependencies
ext-pdo Version *
ext-pdo_mysql Version *
ext-json Version *
ext-ftp Version *