[pve-devel] [PATCH ha-manager 0/8] simulate and cope with unavailable cfs

Thomas Lamprecht t.lamprecht at proxmox.com
Wed Nov 22 11:53:05 CET 2017


This series adds functionallity to simulate and nor read/writeable or
not updatable cluster file system.

First add the simulation parts, then allow the code to cope with a
failure and revert the workaround patch where we simply ignored such
errors.
Finnally move some untested code under the simulation/test umbrella and
add checks and tests if cfs_updates worked.

Please review.

cheer,
Thomas

Thomas Lamprecht (7):
  test/sim: allow to simulate cfs failures
  lrm: handle an error during service_status update
  CRM: refactor check if state transition to active is ok
  Revert "wrap possible problematic cfs_read_file calls in eval"
  move start/end hooks to common code
  move cfs update to common code and check if it worked
  do not do active work if cfs update failed

 src/PVE/HA/CRM.pm                              | 65 +++++++++++++++++++++-----
 src/PVE/HA/Config.pm                           | 13 +++---
 src/PVE/HA/Env.pm                              |  7 +++
 src/PVE/HA/Env/PVE2.pm                         | 15 +++++-
 src/PVE/HA/LRM.pm                              | 46 +++++++++++++++++-
 src/PVE/HA/Manager.pm                          |  1 -
 src/PVE/HA/Sim/Env.pm                          | 38 ++++++++++++++-
 src/PVE/HA/Sim/Hardware.pm                     | 23 +++++++++
 src/PVE/HA/Sim/RTHardware.pm                   |  8 ----
 src/PVE/HA/Sim/TestEnv.pm                      |  4 +-
 src/PVE/HA/Sim/TestHardware.pm                 | 12 +----
 src/PVE/HA/Tools.pm                            | 15 ------
 src/PVE/Service/pve_ha_crm.pm                  |  8 +---
 src/PVE/Service/pve_ha_lrm.pm                  |  8 +---
 src/test/test-cfs-unavailable1/README          |  1 +
 src/test/test-cfs-unavailable1/cmdlist         |  5 ++
 src/test/test-cfs-unavailable1/hardware_status |  5 ++
 src/test/test-cfs-unavailable1/log.expect      | 59 +++++++++++++++++++++++
 src/test/test-cfs-unavailable1/manager_status  |  1 +
 src/test/test-cfs-unavailable1/service_config  |  5 ++
 src/test/test-cfs-unavailable2/README          |  1 +
 src/test/test-cfs-unavailable2/cmdlist         |  5 ++
 src/test/test-cfs-unavailable2/hardware_status |  5 ++
 src/test/test-cfs-unavailable2/log.expect      | 49 +++++++++++++++++++
 src/test/test-cfs-unavailable2/manager_status  |  1 +
 src/test/test-cfs-unavailable2/service_config  |  5 ++
 26 files changed, 331 insertions(+), 74 deletions(-)
 create mode 100644 src/test/test-cfs-unavailable1/README
 create mode 100644 src/test/test-cfs-unavailable1/cmdlist
 create mode 100644 src/test/test-cfs-unavailable1/hardware_status
 create mode 100644 src/test/test-cfs-unavailable1/log.expect
 create mode 100644 src/test/test-cfs-unavailable1/manager_status
 create mode 100644 src/test/test-cfs-unavailable1/service_config
 create mode 100644 src/test/test-cfs-unavailable2/README
 create mode 100644 src/test/test-cfs-unavailable2/cmdlist
 create mode 100644 src/test/test-cfs-unavailable2/hardware_status
 create mode 100644 src/test/test-cfs-unavailable2/log.expect
 create mode 100644 src/test/test-cfs-unavailable2/manager_status
 create mode 100644 src/test/test-cfs-unavailable2/service_config

-- 
2.11.0





More information about the pve-devel mailing list