Before umounting and removing lvm volume, we need to make sure we are
not within the mount point that is to be removed.
Previous logic lacks consideration that path can have parts like
trailing slashes, which could end up skipping changing dir when it is
This patch proposes to normalize the path before doing the check to
avoid such mistakes.
For the time being, the path_to_backup for backup with lvm snapshot
is not taken directly from --path-to-backup parameter, but adjusted
according the mount info of the corresponding volume hinted by that
parameter. However this info is inferred before the volume is actually
mounted so it tends to be inaccuate and leads to errors.
So do the calculation after volume mounting instead.
license boilerplates as docstring are included in automatically
generated documentation which leads to wrong formatting.
For example the indented hyperlink to the license is formatted as
Enable treading warnings as errors so that no new broken stuff gets
merged. Remove obsolete way of doing it, it's a nop.
Fix bugs found:
* Add missing sphinx modules to properly generate content.
* Misformatting of comments and files
* Do not index the windows modules, they import modules that do not
exist on Linux.
* Place api docs in reference/api according to
and reference it. Update .gitignore for this.
* Include missing files in tree.
Standardize on oslo.log.
Log exception stack traces where appropriate.
Add logging to all files.
Remove '[*]' from log messages.
Log command line arguments at Freezer Agent start
so that errors can be traced to specific invocations.
Leave scheduler module mostly unchanged because it
is doing python logging configuration.
If a '%' is part of the freezer option --lvm-snapsize
--extends option will be used instead of --size for the snapshot.
1) new snapshot module with code vss,
lvm and part of backup.py -
create_snapshot and remove_snapshot
This module should contain all code related shadow,
vss and any new snapshots.
2) new openstack module with code from osclient,
restore and backup (BackupOS)
This module should contain code related to cinder/nova backups
3) new utils module with code from utils, win_utils,
bandwidth, config, exec_cmd, validator, streaming
This module should containd code related to anything
that cannot be extracted to its own module
4) new test modules - snapshot, utils, openstack and apiclient.
Test scheduler daemon is now located in scheduler module.
5) Backup.py is deleted and code placed to
openstack.backup (BackupOS) and to job.BackupJob