public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH cluster/container/manager/qemu-server/storage 0/7] combine and simplify RRD handling
@ 2025-09-05 13:55 Aaron Lauterer
  2025-09-05 13:55 ` [pve-devel] [PATCH cluster 1/3] rrd: fix rrd time frames Aaron Lauterer
                   ` (6 more replies)
  0 siblings, 7 replies; 9+ messages in thread
From: Aaron Lauterer @ 2025-09-05 13:55 UTC (permalink / raw)
  To: pve-devel

this series does two things:
* switch the RRD API backend to use the old RRD files is available
  * only data for frontend graphs
  * PNG generation
* always use RRD files with the new 9.0 schema in pmxcfs/status.c
* hardcode pve-TYPE-9.0 paths in the RRD api endpoints for
  * nodes
  * VMs
  * CTs
  * Storage

The motivation for the combination of old and new RRD files is that during the
migration of old RRD files to the new ones, spikes get flattened. By combining
the old and new RRD files, we can keep the old coarse data with all it spikes
and only show the new much mode finer stepped data where available.

This also enables us to just write any new data into an RRD file that is
created with the new 9.0 schema. As a result, no migration step is needed
anymore and we can simplify the logic around the whole "does the only the old
file exist or is the new one also present" alot in quite a few places.

This series does not remove the rrd migration tool or its dependencies. That
still needs to happen. We want to keep the check in the pve8to9 tool, because we
will need the additional space in any case.

cluster:

Aaron Lauterer (3):
  rrd: fix rrd time frames
  RRD: fetch data from old rrd file if present and needed
  pmxcfs: status.c: always use 9.0 rrd files

 src/PVE/RRD.pm      | 162 ++++++++++++++++++++++--------
 src/pmxcfs/status.c | 238 ++++++--------------------------------------
 2 files changed, 153 insertions(+), 247 deletions(-)


manager:

Aaron Lauterer (1):
  status: rrddata: use fixed pve-node-9.0 path

 PVE/API2/Nodes.pm | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)


qemu-server:

Aaron Lauterer (1):
  status: rrddata: use fixed pve-vm-9.0 path

 src/PVE/API2/Qemu.pm | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)


container:

Aaron Lauterer (1):
  status: rrddata: use fixed pve-vm-9.0 path

 src/PVE/API2/LXC.pm | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)


storage:

Aaron Lauterer (1):
  status: rrddata: use fixed pve-storage-9.0 path

 src/PVE/API2/Storage/Status.pm | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)


Summary over all repositories:
  6 files changed, 176 insertions(+), 270 deletions(-)

-- 
Generated by git-murpp 0.8.1


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel


^ permalink raw reply	[flat|nested] 9+ messages in thread
* [pve-devel] [RFC many 0/3] combine and simplify RRD handling
@ 2025-09-04 14:09 Aaron Lauterer
  2025-09-04 14:09 ` [pve-devel] [PATCH cluster 1/3] rrd: fix rrd time frames Aaron Lauterer
  0 siblings, 1 reply; 9+ messages in thread
From: Aaron Lauterer @ 2025-09-04 14:09 UTC (permalink / raw)
  To: pve-devel

this series does two things:
* switch the RRD API backend to use the old RRD files is available
* always use RRD files with the new 9.0 schema

The motivation for the combination of old and new RRD files is that during the
migration of old RRD files to the new ones, spikes get flattened. By combining
the old and new RRD files, we can keep the old coarse data with all it spikes
and only show the new much mode finer stepped data where available.

This will also enable us to just write any new data into an RRD file that is
created with the new 9.0 schema. As a result, no migration step is needed
anymore and we can simplify the logic around the whole "does the only the old
file exist or is the new one also present" alot in quite a few places.

Some examples which we can simplify or revert:
pve-manager: API2Tools::get_rrd_key can most likely be dropped
qemu-server, pve-storage, pve-container,…: rrd API endpoints which check which files exist
drop the whole migration step on upgrade

other TODOs:

RRD::create_rrd_graph -> see if we can combine both files into one graph. But we
are relying on RRD itself for this. So that might be interesting. On the other
hand, do we want to keep that API endpoint around? People are using it though.
So we need to weigh that decision accoringly.


This is currently marked as RFC. Tested by installing it on an existing 9.0.6
cluster. Added a 8.4 node with latest updates. Renamed {rrd}.old to {rrd}.

cluster:

Aaron Lauterer (3):
  rrd: fix rrd time frames
  RRD: fetch data from old rrd file if present and needed
  pmxcfs: status.c: always use 9.0 rrd files

 src/PVE/RRD.pm      | 113 ++++++++++++++-------
 src/pmxcfs/status.c | 238 ++++++--------------------------------------
 2 files changed, 108 insertions(+), 243 deletions(-)


Summary over all repositories:
  2 files changed, 108 insertions(+), 243 deletions(-)

-- 
Generated by git-murpp 0.8.1


_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2025-09-05 13:55 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-09-05 13:55 [pve-devel] [PATCH cluster/container/manager/qemu-server/storage 0/7] combine and simplify RRD handling Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH cluster 1/3] rrd: fix rrd time frames Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH cluster 2/3] RRD: fetch data from old rrd file if present and needed Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH cluster 3/3] pmxcfs: status.c: always use 9.0 rrd files Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH manager 1/1] status: rrddata: use fixed pve-node-9.0 path Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH qemu-server 1/1] status: rrddata: use fixed pve-vm-9.0 path Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH container " Aaron Lauterer
2025-09-05 13:55 ` [pve-devel] [PATCH storage 1/1] status: rrddata: use fixed pve-storage-9.0 path Aaron Lauterer
  -- strict thread matches above, loose matches on Subject: below --
2025-09-04 14:09 [pve-devel] [RFC many 0/3] combine and simplify RRD handling Aaron Lauterer
2025-09-04 14:09 ` [pve-devel] [PATCH cluster 1/3] rrd: fix rrd time frames Aaron Lauterer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal