stoney conductor: prov-backup-kvm
Overview
The Provisioning-Backup-KVM Daemon is written in Perl and uses the mechanisms described under stoney core: OpenLDAP directory data organisation.
Workflow
This is the simplified workflow for the Provisioning-Backup-KVM Daemon. The Subroutines (snapshot, merge and retain) are shown later.
You can modify/update this workflow by editing File:KVM-Backup-simple.xmi (you may need Umbrello UML Modeller diagram programme for KDE to display the content properly).
Snapshot
You can edit this workflow with the following file (you may need umbrello to modify it): File:KVM-Backup-Workflow-detailed.xmi
Merge
You can edit this workflow with the following file (you may need umbrello to modify it): File:KVM-Backup-Workflow-detailed.xmi
Retain
You can edit this workflow with the following file (you may need umbrello to modify it): File:KVM-Backup-Workflow-detailed.xmi
Exit codes
### Error codes constants use constant SUCCESS_CODE => 0; use constant UNDEFINED_ERROR => 1; # Always the first! use constant MISSING_PARAMETER_IN_CONFIG_FILE => 2; use constant CONFIGURED_RAM_DISK_IS_NOT_VALUD => 3; use constant NOT_ENOUGH_SPACE_ON_RAM_DISK => 4; use constant CANNOT_SAVE_MACHINE_STATE => 5; use constant CANNOT_WRITE_TO_BACKUP_LOCATION => 6; use constant CANNOT_COPY_FILE_TO_BACKUP_LOCATION => 7; use constant CANNOT_COPY_IMAGE_TO_BACKUP_LOCATION => 8; use constant CANNOT_COPY_XML_TO_BACKUP_LOCATION => 9; use constant CANNOT_COPY_BACKEND_FILE_TO_BACKUP_LOCATION=> 10; use constant CANNOT_MERGE_DISK_IMAGES => 11; use constant CANNOT_REMOVE_OLD_DISK_IMAGE => 12; use constant CANNOT_REMOVE_FILE => 13; use constant CANNOT_CREATE_EMPTY_DISK_IMAGE => 15; use constant CANNOT_RENAME_DISK_IMAGE => 16; use constant CANNOT_CONNECT_TO_BACKEND => 17; use constant WRONG_STATE_INFORMATION => 18; use constant CANNOT_SET_DISK_IMAGE_OWNERSHIP => 19; use constant CANNOT_SET_DISK_IMAGE_PERMISSION => 20; use constant CANNOT_RESTORE_MACHINE => 21; use constant CANNOT_LOCK_MACHINE => 22; use constant CANNOT_FIND_MACHINE => 23; use constant CANNOT_COPY_STATE_FILE_TO_RETAIN => 24; use constant RETAIN_ROOT_DIRECTORY_DOES_NOT_EXIST => 25; use constant BACKUP_ROOT_DIRECTORY_DOES_NOT_EXIST => 26; use constant CANNOT_CREATE_DIRECTORY => 27; use constant CANNOT_SAVE_XML => 28; use constant CANNOT_SAVE_BACKEND_ENTRY => 29; use constant CANNOT_SET_DIRECTORY_OWNERSHIP => 30; use constant CANNOT_SET_DIRECTORY_PERMISSION => 31; use constant CANNOT_FIND_CONFIGURATION_ENTRY => 32; use constant BACKEND_XML_UNCONSISTENCY => 33; use constant CANNOT_CREATE_TARBALL => 34; use constant UNSUPPORTED_FILE_TRANSFER_PROTOCOL => 35; use constant UNKNOWN_BACKEND_TYPE => 36; use constant MISSING_NECESSARY_FILES => 37; use constant CORRUPT_DISK_IMAGE_FOUND => 38; use constant UNSUPPORTED_CONFIGURATION_PARAMETER => 39; use constant CANNOT_MOVE_DISK_IMAGE_TO_ORIGINAL_LOCATION=> 40; use constant CANNOT_DEFINE_MACHINE => 41; use constant CANNOT_START_MACHINE => 42; use constant CANNOT_WORK_ON_UNDEFINED_OBJECT => 43; use constant CANNOT_READ_STATE_FILE => 44; use constant CANNOT_READ_XML_FILE => 45; use constant NOT_ALL_FILES_DELETED_FROM_RETAIN_LOCATION => 46; use constant NOT_ENOUGH_DISK_SPACE => 47; use constant NO_DISK_SPACE_INFORMATION => 48;
Next steps
- Change the behaviour of the snapshot/merge process
- No longer merge the original file into the new one but merge (commit) backing store file back into original one
- Like that we are able to reduce the backup (merge) time a lot.
- Needs different behaviour for save -> copy/move -> create new image -> restore -> merge
- No longer merge the original file into the new one but merge (commit) backing store file back into original one