2. Tutorials

This section contains tutorials explaining the use of the zhmcclient package.

Each tutorial is a Jupyter Notebook (formerly known as IPython Notebook). In order to view a tutorial, just click on a link in the table below. This will show the tutorial in the online Jupyter Notebook Viewer.


Short description


1: Basics about Jupyter notebooks


2: Connecting to an HMC


3: Basics about working with HMC resources


4: Error handling

2.1. Executing code in the tutorials

In order to execute and also modify the code in the tutorials, Jupyter Notebook needs to be installed in a Python environment, preferrably in a virtual Python environment, and you need to have the notebook files locally.

There are two options on how to do that:

  1. Set up the development environment for zhmcclient (see Setting up the development environment). This will provide you with an installation of Jupyter Notebook and with all the tutorial notebooks in directory docs/notebooks.

    To start Jupyter Notebook with all tutorial notebooks, issue from the repo work directory:

    $ jupyter notebook --notebook-dir=docs/notebooks

    If you intend to keep your changes locally, you may want to work on a copy of the docs/notebooks directory that is outside of the repo work directory.

  2. Install Jupyter Notebook and the zhmcclient package into a Python environment (preferrably virtual):

    $ pip install jupyter zhmcclient

    and download the tutorial notebooks using the download button in the Jupyter Notebook Viewer (following the links in the table above).

    To start Jupyter Notebook with the downloaded tutorial notebooks, issue:

    $ jupyter notebook --notebook-dir={your-notebook-dir}