public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
From: "DERUMIER, Alexandre" <Alexandre.DERUMIER@groupe-cyllene.com>
To: "pve-devel@lists.proxmox.com" <pve-devel@lists.proxmox.com>
Subject: Re: [pve-devel] cluster resource scheduler question
Date: Wed, 23 Nov 2022 10:18:48 +0000	[thread overview]
Message-ID: <0606073a4b72f9a06bbb83e5f2bcb36a9ed24ccd.camel@groupe-cyllene.com> (raw)
In-Reply-To: <19713dd51749ed24a5ecda1c6930191ed8fc4c11.camel@groupe-cyllene.com>

After doing some test, 


if I understand, the node static infos max-mem, max-cpu are only used
to have percents to be able to compare each node.

and the nodeusage is compute with the sum of static mem/cpu of the
services running on this node.

But I really don't see where it's node in the rust code ?


I see a 

+impl StaticNodeUsage {
+    /// Add usage of `service` to the node's usage.
+    pub fn add_service_usage(&mut self, service: &StaticServiceUsage)
{
+        self.cpu = add_cpu_usage(self.cpu, self.maxcpu as f64,
service.maxcpu);
+        self.mem += service.maxmem;
+    }
+}


But I don't see where it's called ?


(BTW, I don't see the repo in proxmox git ?)


Le mardi 22 novembre 2022 à 16:43 +0000, DERUMIER, Alexandre a écrit :
> Hi,
> 
> I was looking at the proxmox 7.3 video
> https://www.proxmox.com/en/training/video-tutorials/item/what-s-new-in-proxmox-ve-7-3
> 
> showing the new cluster resource scheduling with static-ressource.
> 
> I'm not sure to understand, but the video seem to say that vm is
> migrated to the least "loaded" node.
> 
> 
> But looking at static-info of the node,  cpu && memory are the
> physical
> core number && full memory size
> 
> (in pvestatd,
> 
>     broadcast_static_node_info($maxcpu, $meminfo->{memtotal});
>      my sub broadcast_static_node_info {
>       ...
>         my $info = {
>             cpus => $cpus,
>             memory => $memory,
>      }
> 
> 
> I'm not sure about the logic, but if we only look at number of total
> cpus && memory without current usage, the biggest node will always be
> choose ?  or does I miss something ?
> _______________________________________________
> pve-devel mailing list
> pve-devel@lists.proxmox.com
> https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
> 


  parent reply	other threads:[~2022-11-23 10:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-22 16:43 DERUMIER, Alexandre
2022-11-23  9:09 ` Fiona Ebner
2022-11-23 10:58   ` Thomas Lamprecht
2022-11-23 10:18 ` DERUMIER, Alexandre [this message]
2022-11-23 11:28   ` Fiona Ebner
2022-11-23 12:18     ` DERUMIER, Alexandre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0606073a4b72f9a06bbb83e5f2bcb36a9ed24ccd.camel@groupe-cyllene.com \
    --to=alexandre.derumier@groupe-cyllene.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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