Added a new cls 'snapshot_get' method that retrieves all snapshot
specific details to avoid the need to add a new cls method to
retrieve each individual snapshot data field.
The cls 'get_snapshot_namespace' method has been dropped since Luminous
clients will treat that as a user-generated snapshot (and that's all
that is supported by Luminous clients). The cls 'get_snapshot_timestamp'
method has been deprecated and can be removed once <=Luminous clients
are no longer supported.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
The methods are used by the luminous release of librbd but are essentially
no-ops since group support was removed from the API. However, we need to
prevent odd interactions once a new client creates a group and uses an
older client to manipulate the image.
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
* add an option named "MGR_PYTHON_VERSION", so we can build ceph-mgr
which use py3 for running plugins
* also drop the line to specify the "Python_ADDITIONAL_VERSIONS", because
2.7 is listed by all the the FindPythonInterp and FindPythonLibs in
cmake 2.8.12 and up.
* use ${MGR_PYTHON_EXECUTABLE} for holding the path to the python
interpreter used by mgr. because this variable might be overwritten by
"find_package(PythonInterp 2 REQUIRED)" when checking for building env
of pybinding for python2.
Signed-off-by: Kefu Chai <kchai@redhat.com>
* add WITH_PYTHON2 option, so we can build python3 bindings only.
* change the default value of WITH_PYTHON3 option to "OFF", as the
option() command in cmake only allow the initial value to be "ON" or
"OFF". we could use a cached string for this option, but i think it
would be more explicit to continue using the option() command.
* fix the installation dir of "ceph_rest_api.py". please note, we still
have a *default* python version, which is specified by the last element
of ${py_vers}. for instance, ${PYTHON_VERSION} will be 3 if ${py_vers}
is 2;3. in this change, 2 is still the default python version, if both
WITH_PYTHON2 and WITH_PYTHON3 are enabled.
Signed-off-by: Kefu Chai <kchai@redhat.com>
As a follow-up to d7b493a710 we need to stop guarding
ceph-osdomap-tool
ceph-monstore-tool
with WITH_TESTS because they have been moved out of the ceph-test package.
(N.B. ceph-kvstore-tool was also moved out of ceph-test, but apparently never
had the guard.)
Signed-off-by: Nathan Cutler <ncutler@suse.com>
Sometimes the build machine has lots of processor cores and not enough
memory to successfully build Ceph on all of them at once. Calculate
how many parallel build processes we can sustain with the memory we
have and set a lower build parallelism if necessary. Never exceed
the value set by %_smp_mflags even if memory is aplenty.
Credits to Tomáš Chvátal for the original idea and implementation.
Signed-off-by: Nathan Cutler <ncutler@suse.com>
Fixes RPMLINT warning "non-standard-group Development/Libraries"
Also, the Group: line is only needed for SUSE so put it in an appropriate
distro conditional.
Signed-off-by: Nathan Cutler <ncutler@suse.com>
Previously only a service with debug_ms>=1 would dump
corrupt messages: in an upgrade test we're *alway*
interested in a corrupt message.
Signed-off-by: John Spray <john.spray@redhat.com>
list_modules is really about searching for them
on disk, so it's now probe_modules and private.
Both methods now return values instead of populating
an argument, since when called they were always writing into
a newly constructed container.
Signed-off-by: John Spray <john.spray@redhat.com>
Enable people to see can_run failures and the explanatory
messages (telling them about a missing dependency)
before trying to enable a module.
Signed-off-by: John Spray <john.spray@redhat.com>
...and for all modules, not just the active ones.
This enables us to give better feedback to the user
when they try and use a command from a disabled module,
and also fixes the race between enabling a module and
trying to use its commands.
Fixes: http://tracker.ceph.com/issues/21683
Signed-off-by: John Spray <john.spray@redhat.com>
This is to enable us to learn more about the module
before it is enabled, such as whether its can_run method
return true.
We can also use this to enable loading a module's
commands before it is enabled, to give the user
a better response when they try to use a command
belong to a module that is not loaded.
Signed-off-by: John Spray <john.spray@redhat.com>