X2Go Bug report logs - #1316
many connections within the loadchecker sleeping time frame

version graph

Package: x2gobroker; Maintainer for x2gobroker is X2Go Developers <x2go-dev@lists.x2go.org>; Source for x2gobroker is src:x2gobroker.

Reported by: Walid MOGHRABI <w.moghrabi@servicemagic.eu>

Date: Mon, 13 Aug 2018 10:50:02 UTC

Severity: normal

Found in version 0.0.4.0-0~1038~ubuntu16.04.1

Full log


Message #5 received at submit@bugs.x2go.org (full text, mbox, reply):

Received: (at submit) by bugs.x2go.org; 13 Aug 2018 10:49:24 +0000
From w.moghrabi@servicemagic.eu  Mon Aug 13 12:49:22 2018
X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on
	ymir.das-netzwerkteam.de
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=3.0 tests=BAYES_50 autolearn=ham
	autolearn_force=no version=3.4.1
Received: from localhost (localhost [127.0.0.1])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTP id 8DA4B5DAEA
	for <submit@bugs.x2go.org>; Mon, 13 Aug 2018 12:49:22 +0200 (CEST)
X-Virus-Scanned: Debian amavisd-new at ymir.das-netzwerkteam.de
Received: from ymir.das-netzwerkteam.de ([127.0.0.1])
	by localhost (ymir.das-netzwerkteam.de [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id C2zKStvRr_vT for <submit@bugs.x2go.org>;
	Mon, 13 Aug 2018 12:49:16 +0200 (CEST)
Received: from zm-01.servicemagic.eu (zm-01.servicemagic.eu [176.31.236.17])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTPS id 59A2C5DAE9
	for <submit@bugs.x2go.org>; Mon, 13 Aug 2018 12:49:16 +0200 (CEST)
Received: from localhost (localhost.localdomain [127.0.0.1])
	by zm-01.servicemagic.eu (Postfix) with ESMTP id E550C81490A02
	for <submit@bugs.x2go.org>; Mon, 13 Aug 2018 12:49:15 +0200 (CEST)
X-Amavis-Modified: Mail body modified (using disclaimer) -
	zm-01.servicemagic.eu
X-Virus-Scanned: amavisd-new at servicemagic.eu
Received: from zm-01.servicemagic.eu ([127.0.0.1])
	by localhost (zm-01.servicemagic.eu [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id ubKS3X+5braq for <submit@bugs.x2go.org>;
	Mon, 13 Aug 2018 12:49:15 +0200 (CEST)
Received: from zm-01.servicemagic.eu (localhost.localdomain [127.0.0.1])
	by zm-01.servicemagic.eu (Postfix) with ESMTP id 9330C8130A553
	for <submit@bugs.x2go.org>; Mon, 13 Aug 2018 12:49:15 +0200 (CEST)
Date: Mon, 13 Aug 2018 12:49:15 +0200 (CEST)
From: Walid MOGHRABI <w.moghrabi@servicemagic.eu>
To: submit@bugs.x2go.org
Message-ID: <642547301.4002690.1534157355564.JavaMail.root@servicemagic.eu>
In-Reply-To: <1570242647.4002488.1534157164350.JavaMail.root@servicemagic.eu>
Subject: many connections within the loadchecker sleeping time frame
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
X-Originating-IP: [195.200.167.70]
X-Mailer: Zimbra 7.2.0_GA_2669 (ZimbraWebClient - GC68 (Linux)/7.2.0_GA_2669)
package: x2gobroker
version: 0.0.4.0-0~1038~ubuntu16.04.1
priority: enhancement


I'm not really sure of that because it is pretty hard to reproduce that one but I have the impression that, if you have many users connecting nearly at the same time (and especially within the loadchecker sleep time which is 300s by default), the load factor value is not recalculated and thus, you might have many users sent to the same server instead of beeing equally distributed of the farm.
Sometime, I have 3, 4, 5 ... users sent to the same server while I have a few servers empty of connected users.
This is a race condition but every morning, it can happen since our users starts between 8:30AM and 9:30AM and we have about 100 users so you can easily have 5~6 people connecting in less than a minute.

I think the load calculation should be more dynamic and not strictly done every x minutes.

For example, you can still do the load calculation every 5mn in order to "reset" load values once but then, I think something like this could be done :
  * calculate the load every x minutes ("bootstrap" calculation)
  * user A logging in, broker asks loadchecker for a server to connect the user, loadchecker respond "server-01"
  * user A is sent to "server-01" and then, "server-01" is locked for a few seconds (5, 10, ... maybe user defined) (blocked for new incoming connections)
  * broker asks loadchecker to re-calculate the load value for "server-01" only
  * "server-01" is unlocked for new incoming connections

That way, load value is recalculated "on demand" in real time and connections are sure to be retargeted to more available servers while this calculation is done.
---
DISCLAIMER: This e-mail is private and confidential and may contain proprietary or legally privileged information. It is for the intended recipient only. If you have received this email in error, please notify the author by replying to it and then destroy it. If you are not the intended recipient you must not use, disclose, distribute, copy, print or rely on this e-mail or any attachment. Thank you


Send a report that this bug log contains spam.


X2Go Developers <owner@bugs.x2go.org>. Last modified: Thu Nov 21 15:20:54 2024; Machine Name: ymir.das-netzwerkteam.de

X2Go Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.