Server backup strategy
Backup strategy
What to backup?
- Databases
- Website files
- Configuration files
- Mail data
Automatic backups
#!/bin/bash
DATUM=$(date +%Y%m%d)
# Database
mysqldump -u root -p'password' --all-databases > /backups/db_$DATUM.sql
# Files
tar -czf /backups/www_$DATUM.tar.gz /var/www/
# Remove old
find /backups -mtime +7 -delete
Cronjob
0 3 * * * /root/backup.sh
External storage
- rsync to other server
- S3 compatible storage
- FTP/SFTP
Need help?
We're here for you! Running into issues or have questions? Our support team is happy to help you personally. Drop us a message through the ticket system - we usually respond within a few hours and love helping you find the best solution.
Was dit artikel nuttig?
0 van 0 vonden dit nuttig