]> git.proxmox.com Git - pve-ha-manager.git/commit - src/PVE/HA/Sim/Env.pm
add after_fork method to HA environment and use it in LRM
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Wed, 27 Jan 2016 12:16:33 +0000 (13:16 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Wed, 27 Jan 2016 15:57:44 +0000 (16:57 +0100)
commita2aae08ae5439aff276a9d887b324eb9c1fea763
tree29cf166a307a63de2343d86ad288ba3095628976
parent0b344d4d391aeee543bec67cfcd216406f852766
add after_fork method to HA environment and use it in LRM

As both the realtime simulator and the real world Environment can
fork but we only need to clean up after a fork in the real world
introduce a after_fork method

In PVE2 it closes the inherited INotify fd and reopens it for the
worker.
Also a cfs_update gets triggered as (other) workers may change the
cluster state.

also use the new introduction HA-Env method to clean up after
we forked an LRM worker.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/HA/Env.pm
src/PVE/HA/Env/PVE2.pm
src/PVE/HA/LRM.pm
src/PVE/HA/Sim/Env.pm