From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 438346160E for ; Tue, 13 Oct 2020 14:05:36 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 2A38DEDE3 for ; Tue, 13 Oct 2020 14:05:36 +0200 (CEST) Received: from mail-lf1-x12a.google.com (mail-lf1-x12a.google.com [IPv6:2a00:1450:4864:20::12a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 5B7F6EDCE for ; Tue, 13 Oct 2020 14:05:34 +0200 (CEST) Received: by mail-lf1-x12a.google.com with SMTP id d24so21798796lfa.8 for ; Tue, 13 Oct 2020 05:05:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=odiso-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=tW2BE/C5ZwxVIqayMwI8uBQkofv1/QphVl+TBVAAqfc=; b=T+gdH6c0K0Weix4dRChYVnZdve2AJ/Bm4ZjJWQMbwvOKjS8P05GVAv/jYnybk9BsrE R1GWsHG7/kRXTkEO9adXgZwYqhMQ826sTC670iHimfbWymZGcenr8GkEuVq2UUkseJEO vEkTqtk7qyGJ+3mHrkuLjIgEUq5T2CTpS4q/rsYxxTqrgb5AULCS3FndrVCXtNYNfmfk 4s+ewYOw25LN5fsZcqfxZqwmOobHsgc2sIDXxtm1VeVzmlAaqyIOMw/QzOJYLl3ruNqt mbYZOfG8ynapXPQsyBO5TFQSPzYXQnLUFkt1M8NNtmzIwWMfII8kFmDivSmcZjxrcE+r 7E6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=tW2BE/C5ZwxVIqayMwI8uBQkofv1/QphVl+TBVAAqfc=; b=nLvo9er+NGXxp/jj06xAAOTrAlCiardEy95ndG5FVGgtnc43EZiBcz7mt7FsVcZufh snWh+WcrXGkcJr9o+YQ5hKpmC06VZN2NVc9RLXwIAOAgYv9a9GLaB94P3IlzF+Qo+Pcb BVPo5rhTNDPAmuskEJPOmaWYZpcCN153JBF/Iel9r6+nXZcenUYlsXQXfu7FS1Q1rpCv acuYmYLOG8MpOZ/SI/Zra38ups/xpNvTNVcXZltr+nG08N/F9lnwbGWjrYcJpkJZbgBI y9iM7ZKjD8Bu/dmb5ovbc3in1MzJoF1LovbRmd7geJmtEgNORIPA3sT55T4LRB27GS8G Q0mg== X-Gm-Message-State: AOAM532XerAj+HzZ2XKIdTIZDHtwIikhY4S1BuWjbC3VnDYsvgQ66Tbh +OHn2y3zYxRwMC/Wi9FHNgmfhRp7Fs69khzTfbCNJLRhYBznKPMk X-Google-Smtp-Source: ABdhPJz0CHadGDjtgq+7Zo4IA5d/MM0KJ3y5JC3oQ8FYs370x22ey88XmzjgOqVEEzfGWyjiA1T6qk9SAFWefUaN/t8= X-Received: by 2002:a19:c811:: with SMTP id y17mr1236274lff.259.1602590727644; Tue, 13 Oct 2020 05:05:27 -0700 (PDT) MIME-Version: 1.0 References: <20201006115839.1026402-1-aderumier@odiso.com> <20201006115839.1026402-2-aderumier@odiso.com> <190420382.634.1602569100580@webmail.proxmox.com> <786323871.4.1602574695068@webmail.proxmox.com> In-Reply-To: <786323871.4.1602574695068@webmail.proxmox.com> From: Alexandre Derumier Date: Tue, 13 Oct 2020 14:05:16 +0200 Message-ID: To: Dietmar Maurer Cc: Proxmox VE development discussion X-SPAM-LEVEL: Spam detection results: 0 DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature HTML_MESSAGE 0.001 HTML included in message RCVD_IN_DNSWL_NONE -0.0001 Sender listed at https://www.dnswl.org/, no trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 Subject: Re: [pve-devel] [PATCH pve-common 1/1] ProcFSTools: add read_pressure X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Oct 2020 12:05:36 -0000 >>Why do you need 10s resulution? Isn't 1min good enough? Well, if the 1min is an average of 10s metric, it's ok. I'm currently using 1min average and 5min average, so it's not a problem with current rrds. Thanks for the informations ! (I'll resend a patch to add pressure to rrd, and also add vm/ct pressure) Le mar. 13 oct. 2020 =C3=A0 09:38, Dietmar Maurer a = =C3=A9crit : > > BTW, I'm currently playing with reading the rrd files, and I have notic= e > than lower precision is 1minute. > > as pvestatd send values around each 10s, is this 1minute precision an > average of 6x10s values send by pvestatd ? > > Yes (we also store the MAX) > > > I'm currently working on a poc of vm balancing, but I would like to hav= e > something like 15min of 10s precision (90 samples of 10s). > > Why do you need 10s resulution? Isn't 1min good enough? > > > So currently I'm getting stats each 10s manually > with PVE::API2Tools::extract_vm_stats like the ressource api. > > (This use PVE::Cluster::rrd_dump , but I don't understand the ipcc_. > code. does it only return current streamed values? > > then after the rrdcached daemon is writing to rrd file the average > values each minute ?) > > > > I don't known if we could have rrd files with 15min of 10s precision ? > (don't known the write load impact on disks) > > We use the following RRD conf, step is 60 seconds (see > pve-cluster/src/status.c): > > static const char *rrd_def_node[] =3D { > "DS:loadavg:GAUGE:120:0:U", > "DS:maxcpu:GAUGE:120:0:U", > "DS:cpu:GAUGE:120:0:U", > "DS:iowait:GAUGE:120:0:U", > "DS:memtotal:GAUGE:120:0:U", > "DS:memused:GAUGE:120:0:U", > "DS:swaptotal:GAUGE:120:0:U", > "DS:swapused:GAUGE:120:0:U", > "DS:roottotal:GAUGE:120:0:U", > "DS:rootused:GAUGE:120:0:U", > "DS:netin:DERIVE:120:0:U", > "DS:netout:DERIVE:120:0:U", > > "RRA:AVERAGE:0.5:1:70", // 1 min avg - one hour > "RRA:AVERAGE:0.5:30:70", // 30 min avg - one day > "RRA:AVERAGE:0.5:180:70", // 3 hour avg - one week > "RRA:AVERAGE:0.5:720:70", // 12 hour avg - one month > "RRA:AVERAGE:0.5:10080:70", // 7 day avg - ony year > > "RRA:MAX:0.5:1:70", // 1 min max - one hour > "RRA:MAX:0.5:30:70", // 30 min max - one day > "RRA:MAX:0.5:180:70", // 3 hour max - one week > "RRA:MAX:0.5:720:70", // 12 hour max - one month > "RRA:MAX:0.5:10080:70", // 7 day max - ony year > NULL, > }; > > Also See: man rrdcreate > > So no, you do not get 10s precission from RRD. > >