Commit Graph

4 Commits

Author SHA1 Message Date
Ilya Etingof 7ace4293e9 multiprocess server, ZMQ-based management cli tool
Original design of the VirtualBMC tool was that user manages
config files for individual VirtualBMC (via a cli tool), then
requests the tool to start the instances representing
individual VirtualBMC instances (via the cli tool). Then
the instances become independent processes. The only way
to know their whereabouts is through the pidfiles
they maintain.

There were certain practical inconveniences with the
original design, namely:

* Cumbersome to start/stop/monitor free-standing
  vBMC instances processes
* No two-way communication between the parent process
  and the VirtualBMC instances what makes child state check
  or modification unnecessary difficult

This commit turns server part of the tool into a single
process spawning multiple children processes and herding
them via ZMQ client/server.

The parent process runs server part of the control
interface, maintains persistent VirtualBMC instances
configuration and ensures all its children are alive
and kicking. Each VirtualBMC instance is still a separate
parent fork.

If child dies, parent respawns it right away. If parent
is about to die, it tries its best to kill all the
prospective orphans.

This new implementation tries to stay compatible with
the original one in part of `vbmc` tool CLI interface
and behaviour. Whenever it can't connect to the `vbmcd`
it tries to fork and spawn the daemon behind the scenes.

While the threading design for this tool might look better,
the underlying pyghmi library is apparently rather
complicated to use its concurrency capabilities reliably.
The other minor consideration is that running multiple
processes leverages CPU-based concurrency.

Other changes:

* The `start` command now accepts more than one domains
  to be started

Change-Id: Ie10f4598c7039a7afa9b45d01df3b3c3db252c1d
Story: 1751570
Task:  12057
2018-05-11 17:29:47 +02:00
Ilya Etingof 93043f32a1 rearrange existing documentation to follow the new layout standard
Change-Id: I2ac8f8f78147a5f75a2394f240154ee4472a7879
2017-07-17 14:57:41 +02:00
Lucas Alvares Gomes a63b7e8191 Fix documentation title and README
This patch fixes the documentation title, the name of the project is
VirtualBMC (with the capital cases) and also fix the README, it changes
the order of "team and repository tag" title to be the last and add
graceful shutdown and NMI as supported commands for ipmitool.

Change-Id: Ieb857b4c1065d5fff2028ee78a4a4e8586cd4724
2017-02-10 12:19:44 +00:00
Lucas Alvares Gomes 85a0b201ff Restructure the repository according to OpenStack
This patch is restructuring the VirtualBMC repository according to the
OpenStack template for projects (Cookiecutter).

This patch also removes the dependency on the python-daemon library
since it is not present in the OpenStack global-requirements, now a new
class called "detach_process" has been added to the virtualbmc/utils.py
module that will take care of detaching the process context from its
parent and session.

Change-Id: Id4ae1db5b73a18abc54276fe1dfbf3ceff7adc06
2016-05-09 12:35:50 +01:00