[pve-devel] [PATCH pve-ha-manager] simulator: fix random output of manager status

Thomas Lamprecht t.lamprecht at proxmox.com
Fri Sep 11 16:57:17 CEST 2015


Tell Data::Dumper to sort the keys before dumping. That fixes
the manager status mess of jumping keys.

Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
---
 src/PVE/HA/Sim/RTHardware.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/PVE/HA/Sim/RTHardware.pm b/src/PVE/HA/Sim/RTHardware.pm
index 56a2364..54f6fba 100644
--- a/src/PVE/HA/Sim/RTHardware.pm
+++ b/src/PVE/HA/Sim/RTHardware.pm
@@ -7,6 +7,7 @@ use strict;
 use warnings;
 use POSIX qw(strftime EINTR);
 use Data::Dumper;
+$Data::Dumper::Sortkeys = 1; # fixes 'random' output behaviour of manager status
 use JSON; 
 use IO::File;
 use IO::Select;
-- 
2.1.4



More information about the pve-devel mailing list