hubio-sync validate
Validate connectivity to source and destination systems.
Synopsis
hubio-sync validate [--source <name>] [--destination <name>] [flags]
Description
The validate command tests connectivity to source and/or destination systems without transferring any data. Use this to verify your configuration before running migrations.
The command verifies:
- Source is reachable and readable
- Destination is reachable and writable
- Credentials are valid
- Network connectivity works
Flags
| Flag | Short | Required | Description |
|---|---|---|---|
--source | -s | No* | Source configuration name or ID |
--destination | -d | No* | Destination configuration name or ID |
--verbose | -v | No | Show detailed connection information |
*At least one of --source or --destination is required.
Examples
Validate Both Source and Destination
hubio-sync validate -s mysql-prod -d s3-archive
Output:
Validating source: mysql-prod (MySQL)
✓ Connection successful
✓ Read access confirmed (5 files found)
Validating destination: s3-archive (S3)
✓ Connection successful
✓ Write access assumed (connect succeeded)
✓ All validations passed!
Validate Only Source
hubio-sync validate -s local-files
Output:
Validating source: local-files (FileSystem)
✓ Connection successful
✓ Read access confirmed (1234 files found)
✓ All validations passed!
Validate Only Destination
hubio-sync validate -d s3-backup
Verbose Output
hubio-sync validate -s mysql-prod -d s3-archive --verbose
Output:
Validating source: mysql-prod (MySQL)
Host: prod-db.example.com:3306
✓ Connection successful
✓ Read access confirmed (5 files found)
Validating destination: s3-archive (S3)
Bucket: company-data-archive/backups
Region: us-east-1
✓ Connection successful
✓ Write access assumed (connect succeeded)
✓ All validations passed!
Error Handling
When validation fails, the command reports specific errors:
Validating source: mysql-prod (MySQL)
✗ Connection failed: dial tcp: connection refused
Validating destination: s3-archive (S3)
✓ Connection successful
✓ Write access assumed (connect succeeded)
Error: validation failed with errors
Exit Codes
| Code | Description |
|---|---|
| 0 | All validations passed |
| 1 | One or more validations failed |
Use Cases
Before Running a Migration
Always validate before running a large migration:
# First, validate
hubio-sync validate -s mysql-prod -d s3-archive
# If successful, run the migration
hubio-sync migrate -s mysql-prod -d s3-archive
Troubleshooting Connectivity
Use verbose mode to diagnose connection issues:
hubio-sync validate -s mysql-prod -v
Testing New Configuration
After adding a new source or destination:
# Add new source via GUI or config
hubio-sync validate -s new-database
See Also
- CLI Reference
- migrate - Run migration
- config validate - Validate config file syntax
- Troubleshooting