- :ref:`pywbemcli <Pywbemcli command>` - A command line tool using
the :ref:`Pywbemcli command line interface` with a :ref:`Command mode` and
and :ref:`Interactive mode` that provides command groups and commands for the
pywbemcli client including:
- Explore the CIM data of WBEM servers. It can manage/inspect the CIM model components including CIM classes(:ref:`Class command group`), CIM instances(:ref:`Instance command group`), and CIM qualifiers and execute CIM methods and queries on the WBEM server. Thus, for example, the command :ref:`class enumerate <Class enumerate command>` returns CIM classes from the WBEM server defined by the current :term:`connection definition`.
- Execute specific CIM-XML operations on the WBEM server as defined in DMTF standard :term:`DSP0200` (CIM Operations over HTTP).
- Display the responses in a variety of formats (:ref:`Output formats`)
including viewing in the MOF, XML, pywbem Python formats and as
tables and trees of hierarchical objects such as CIM classes.
- Inspect and manage WBEM server functionality including:
- :term:`CIM namespaces <CIM namespace>` (:ref:`Namespace command group`)
- Advertised WBEM management profiles (:ref:`Profile command group`)
- WBEM server brand and version information (:ref:`Server command group`)
- WBEM server indication subscription data (:ref:`Subscription command group`)
- Inspect and manage WBEM server functionality including:
- Capture detailed information on CIM-XML interactions with the WBEM server including time statistics and details of data flow.
- Maintain a file (:term:`connections file`) with persisted WBEM :term:`connection definitions <connection definition>` so that pywbemcli can access multiple WBEM servers by name. See :ref:`Connection command group`
- Use an integrated :ref:`Mock WBEM Server` to try out commands or demonstrate server capabilities. The mock server can be loaded with CIM objects defined in MOF files or via Python scripts.
- :ref:`pywbemlistener <Pywbemlistener command>` - A command line utility that manages WBEM indication listeners running as background processes on the local system and displays/logs CIM indications received by these listeners.
CIM/WBEM standards are used for a wide variety of systems management tasks in the industry including DMTF management standards and the SNIA Storage Management Initiative Specification (SMI-S).
The pywbemtools package is supported in these environments:
- Operating systems: Linux, Windows (native and Unix-like environments (ex. Cygwin), OS-X
- Python versions: 3.8 and greater
- WBEM servers: Any WBEM server that conforms to the DMTF specifications listed in :ref:`Standards conformance`. WBEM servers supporting older versions of these standards are also supported, but may have limitations. See the pywbem WBEM servers documentation for more details.
This section describes the complete installation of pywbemtools with all steps including prerequisite operating system packages.
The easiest way to install the pywbemtools package is using pip. Pip ensures that any dependent Python packages also get installed.
Pip will install the packages into your currently active Python environment See section :ref:`Using Python virtual environments` for more information on virtual environments.
If you want to contribute to the pywbem project, you need to set up a development and test environment for pywbemtools. That has a larger set of OS-level prerequisites and its setup is described in the :ref:`Pywbemtools development` chapter.
The Python environment into which you want to install must have the following Python packages installed:
- setuptools - http://pypi.python.org/pypi/setuptools
- wheel
- pip
Pywbemtools installs the pywbem package.
When using pywbem versions before 1.0.0 on Python 2, pywbem requires a number of OS-level packages, and your system must have the following commands installed:
- On native Windows:
choco
- Chocolatey package manager. The pywbemtools package installation uses Chocolatey to install OS-level software. See https://chocolatey.org/ for the installation instructions for Chocolatey.wget
- Download tool. Can be installed with:choco install wget
.
- On Linux, OS-X, UNIX-like environments on Windows (e.g. Cygwin):
wget
- Download tool. Can be installed using the OS-level package manager for the platform.
When using pywbem versions before 1.0.0 on Python 2, install the OS-level packages needed by the pywbem package as follows:
On native Windows:
> wget -q https://raw.githubusercontent.com/pywbem/pywbem/master/pywbem_os_setup.bat > pywbem_os_setup.bat
On Linux, OS-X, UNIX-like environments on Windows (e.g. Cygwin):
$ wget -q https://raw.githubusercontent.com/pywbem/pywbem/master/pywbem_os_setup.sh $ chmod 755 pywbem_os_setup.sh $ ./pywbem_os_setup.sh
The
pywbem_os_setup.sh
script uses sudo internally, so your userid needs to have sudo permission.
If you want to install the needed OS-level packages manually, see pywbem prerequisite OS packages.
The following command downloads and installs the latest released version of the pywbemtools package from PyPI into the currently active Python environment:
$ pip install pywbemtools
As an alternative, if you want to install the latest development level of the
pywbemtools package for some reason, install directly from the master
branch of the Git repository of the package:
$ pip install git+https://github.com/pywbem/pywbemtools.git@master#egg=pywbemtools
NOTE: Installing with setup.py install
has been deprecated by
setuptools, as explained in
Why you shouldn't invoke setup.py directly.
Installation with setup.py install
is no longer supported by this package.
NOTE: pywbemtools may also be installed for development and to include the pywbemtools test environment by cloning the pywbemtools git repository as documented in :ref:`Pywbemtools development`.
.. index:: pair; troubleshooting: pywbem
Support for correcting a number of installation issues can be found in the pywbem troubleshooting documentation.
You can verify that the pywbemtools package and its dependent packages are
installed correctly by invoking pywbemcli. Invoking with the --version
option displays the installed version of both pywbem and pywbemtools as
shown in the following example:
$ pywbemcli --version
pywbemcli, version 0.5.0
pywbem, version 0.14.4
Pywbemtools attempts to comply to the maximum possible with the relevant standards.
Pywbemtools uses pywbem for communication with the WBEM server. Therefore pywbemtools conformance to the relevant standards is defined in the pywbem standards conformance documentation.
Therefore, the level of conformance and limitations for pywbemtools is the same as pywbem except for any specific notations in this document.
Pywbemtools attempts to be as backwards compatible as possible.
Occasionally functionality needs to be retired, because it is flawed and a better but incompatible replacement has emerged.
In pywbemtools, such changes are done by deprecating existing functionality, without removing it. The deprecated functionality is still supported throughout new minor releases. Eventually, a new major release will break compatibility and will remove the deprecated functionality.
In order to prepare users of pywbemtools for that, deprecation of functionality
is stated in the CLI documentation, and is made visible at runtime by issuing
Python warnings of type DeprecationWarning
(see the Python
:mod:`py:warnings` module).
Since Python 2.7, DeprecationWarning
messages are suppressed by default.
They can be shown for example by invoking pywbemcli with the environment
variable: PYTHONWARNINGS=default
, or by using the
ref:--warn general option.
It is recommended that users of the pywbemtools package run their test code with
DeprecationWarning
messages being shown, so they become aware of any use of
deprecated functionality.
Here is a summary of the deprecation and compatibility policy used by pywbemtools, by release type:
- New update release (M.N.U -> M.N.U+1): No new deprecations; fully backwards compatible.
- New minor release (M.N.U -> M.N+1.0): New deprecations may be added; as backwards compatible as possible.
- New major release (M.N.U -> M+1.0.0): Deprecated functionality may get removed; backwards compatibility may be broken.
Compatibility is always seen from the perspective of the user of pywbemtools, so a backwards compatible new pywbemtools release means that the user can safely upgrade to that new release without encountering compatibility issues.
This documentation applies to version |release| of the pywbemtools package. You can also see that version in the top left corner of this page.
The pywbemtools package uses the rules of Semantic Versioning 2.0.0 for its version.
This documentation may have been built from a development level of the package. You can recognize a development version of this package by the presence of a ".devD" suffix in the version string. Development versions are pre-versions of the next assumed version that is not yet released. For example, version 0.5.1.dev2 is development pre-version #2 of the next version to be released after 0.5.0. Version 1.5.1 is an assumed next version, because the actually released next version might be 0.7.0 or even 1.0.0.
In this package, compatibility is always seen from the perspective of the user of the package. Thus, a backwards compatible new version of this package means that the user can safely upgrade to that new version without encountering compatibility issues.
This package uses the rules of Semantic Versioning 2.0.0 for compatibility between package versions, and for deprecations.
The public command line interface of this package that is subject to the semantic versioning rules (and specifically to its compatibility rules) is the CLI syntax described in this documentation.
The output formats are currently not the subject of compatibility assurances.
Violations of these compatibility rules are described in section :ref:`Change log`.
If you encounter any problem with this package, or if you have questions of any kind related to this package (even when they are not about a problem), please open an issue in the pywbemtools issue tracker.
This package is licensed under the Apache 2.0 License.