Troubleshooting
Backup & Restore

Backup & Restore Issues

Troubleshoot backup creation, restoration, and storage provider issues in OEC.sh.


Backup Creation Failures

Symptom

Backup creation fails or completes with errors.

Common Causes and Solutions

Insufficient Disk Space

Symptom: Backup fails with "no space left on device" error.

Solution:

  1. Check server disk usage: Server → Metrics
  2. Remove old local backups if needed
  3. Backups require temporary space equal to database size + filestore size

Backups are created locally first, then uploaded to your storage provider. Ensure you have at least 2x your database size in free disk space.

Database Connection Error

Symptom: "pg_dump: connection refused" or similar error.

Solution:

  1. Verify database is running: Environment → Overview
  2. Restart environment if database is down
  3. Check database credentials in environment settings

Storage Provider Unreachable

Symptom: Backup created but upload fails.

Solution:

  1. Verify storage provider credentials: Settings → Storage Providers
  2. Test connection using the "Test Connection" button
  3. Check for network issues or provider outages

Amazon S3 / Cloudflare R2 / Backblaze B2:

  • Verify Access Key and Secret Key
  • Check bucket permissions (put, get, list)
  • Ensure bucket exists and is accessible
  • Verify region is correct

Timeout During Large Backup

Symptom: Backup times out for large databases.

Solution:

  1. Large databases may take longer to back up
  2. Check server resources during backup
  3. Consider scheduling backups during low-usage periods

Restore Failures

Symptom

Backup restoration fails or completes with errors.

Common Causes and Solutions

Incompatible Backup Version

Symptom: "database version mismatch" or migration errors.

Solution:

  1. Check the backup's Odoo version (in backup manifest)
  2. Ensure target environment matches or is compatible
  3. For version upgrades, use Clone with Sanitization feature

Insufficient Resources

Symptom: Restore fails with memory or disk errors.

Solution:

  1. Check server resources: Server → Metrics
  2. Scale up resources temporarily for large restores
  3. Ensure target has more disk space than backup size

Check Backup Size

View backup details to see database and filestore sizes.

Verify Available Space

Go to Server → Metrics and check available disk space.

Scale if Needed

Increase disk allocation: Environment → Settings → Resources

Retry Restore

Attempt the restore again after ensuring adequate resources.

Corrupted Backup File

Symptom: "invalid backup format" or extraction errors.

Solution:

  1. Download and manually verify the backup file
  2. Try restoring from a different backup
  3. Check if the backup provider reported any upload errors

Database Already Exists

Symptom: "database already exists" error during restore.

Solution:

  1. OEC.sh normally handles this automatically
  2. If persists, use Force Restore option
  3. Contact support if the issue continues
⚠️

Restoring a backup will overwrite all existing data in the environment. Always verify you're restoring to the correct environment.


Storage Provider Issues

Symptom

Cannot connect to storage provider or operations fail.

Common Causes and Solutions

Invalid Credentials

Symptom: "access denied" or "authentication failed" error.

Verify Credentials

Go to Settings → Storage Providers and check your configuration.

Test Connection

Click the "Test Connection" button to verify access.

Regenerate Keys

If using access keys, regenerate them from your provider's console.

Update Configuration

Save the new credentials and test again.

Bucket/Container Not Found

Symptom: "bucket not found" or "container does not exist" error.

Solution:

  1. Verify bucket name is correct (case-sensitive)
  2. Check bucket exists in the correct region
  3. Ensure the bucket wasn't accidentally deleted

Permission Denied

Symptom: Can read but not write, or vice versa.

Solution: Required permissions by provider:

ProviderRequired Permissions
S3s3:PutObject, s3:GetObject, s3:ListBucket, s3:DeleteObject
R2Same as S3 (S3-compatible)
B2readFiles, writeFiles, listFiles, deleteFiles
AzureBlob Data Contributor role
GCSStorage Object Admin

Network/Firewall Issues

Symptom: Timeouts or connection refused errors.

Solution:

  1. Verify outbound connections are allowed
  2. Check if provider is experiencing outages
  3. Try from a different network if possible

Large Backup Handling

Symptom

Issues with backups larger than 10GB.

Best Practices for Large Backups

Split Filestore

Consideration: Large filestores increase backup time and size.

Solutions:

  1. Consider using external object storage for large files
  2. Archive old attachments periodically
  3. Clean up unused attachments

Optimize Database

Consideration: Large databases take longer to back up.

Solutions:

  1. Archive old records (e.g., mail.message, ir.logging)
  2. Vacuum the database regularly
  3. Remove unused demo data

OEC.sh uses incremental-friendly backup strategies where possible, but the initial full backup must complete successfully.

Scheduled Backups

Recommendation: Schedule large backups during off-peak hours.

  1. Go to Environment → Backups → Schedule
  2. Set time to low-usage period (e.g., 2 AM)
  3. Configure retention policy (daily, weekly, monthly)

Backup Best Practices

Recommended Configuration

  1. Multiple Storage Providers - Configure at least 2 providers for redundancy
  2. GFS Retention - Use Grandfather-Father-Son retention (daily, weekly, monthly, yearly)
  3. Regular Testing - Periodically test restores on a clone
  4. Before Major Changes - Always create a manual backup before upgrades

Backup Contents

Each OEC.sh backup includes:

  • dump.sql - PostgreSQL database dump
  • filestore.tar.gz - Odoo filestore (attachments, images)
  • manifest.json - Backup metadata (version, timestamp, size)

Recovery Scenarios

Accidental Data Deletion

  1. Identify when the deletion occurred
  2. Find a backup from before that time
  3. Use Clone with Sanitization to restore to a test environment
  4. Verify the data exists in the clone
  5. Export specific records or restore to production

Environment Corruption

  1. Create a new environment
  2. Restore the latest good backup to the new environment
  3. Update DNS/domains if needed
  4. Delete the corrupted environment

Disaster Recovery

  1. Deploy a new server if needed
  2. Create new environments
  3. Restore from off-site backups (S3, R2, B2)
  4. Update configurations and DNS

Still Having Issues?

If the above solutions don't resolve your problem:

  1. Collect Information:

    • Environment ID
    • Backup ID (if applicable)
    • Storage provider type
    • Error messages from logs
  2. Contact Support: Email [email protected]