X-Rcpt-Trace: gkrellm at lists.netservicesgroup.com
Received-SPF: pass (Last token {+ip4:69.39.232.110} (res=PASS)) client-ip=69.39.232.110; envelope-from=<pete@peterhyman.com>; x-ip-name=server315mail1.webhostingpad_com;
X-Received: from server315.webhostingpad.com (unverified [69.39.232.110])
by mailproc.sbbsnet.net (Network-Services-Group-Email) with ESMTP (TLS) id 1567093-1928206
for <gkrellm@lists.netservicesgroup.com>; Mon, 08 Oct 2018 14:21:20 -0400
X-Return-Path: pete
X-Verify-SMTP: Host 69.39.232.110 sending to us was not listening
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=peterhyman.com; s=default; h=Content-Type:Content-Transfer-Encoding:
MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:To:From:Sender:
Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From:
Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:
List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive;
bh=EcC9cLPXldHR1aHEU/8oTrkKMHUyIb9N5PECvDPx2qQ=; b=RpNtsSh5H0SxkbIJTXi9VCjrbX
uyZpiBz6FDEF/RtWrg42kJ/phkP+z6FXmPMJRcmT8UpwA3i5NdqJKBjTCQnwvjLp5KsNI8EXOZ/zM
5Xn7XARv4krq6Xxvm7hXRkthczsJLLe2jiURun7jBoo4j2IG3rPEjW2I+xUSOUa93WaI5UtFqWeF1
503MGrHWLPLCuwvul2IRphn5RgXjTKRbwFwHNcJAGwtt9s+bAOapljku1tcZGscc0dEEmSioyxMvp
jWH/9qkfdCtuABS32NpemfaqqGDi4bDQBEyrPg0JOAgyLxrZEt0s4kTWfCFa0e9Q9l8ZDyuj+/7NF
qKEE2C7A==;
X-Received: from c-174-53-222-166.hsd1.mn.comcast.net ([174.53.222.166]:56946 helo=tommyiv.localnet)
by server315.webhostingpad.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256)
(Exim 4.89_1)
(envelope-from <pete@peterhyman.com>)
id 1g9a9V-002HzD-Dx
for gkrellm@lists.netservicesgroup.com; Mon, 08 Oct 2018 13:21:10 -0500
From: Peter Hyman
To: gkrellm@lists.netservicesgroup.com
Subject: Re: [Gkrellm] Error in krell scale for volume sizes in fs,c
Date: Mon, 08 Oct 2018 13:21:08 -0500
Message-ID: <2373637.nD1ziL7Y46@tommyiv>
User-Agent: KMail/4.14.10 (Linux/4.4.157; KDE/4.14.32; x86_64; ; )
In-Reply-To: <e5768eb2-03d5-0c47-5486-209ecd67fb5b@srcbox.net>
References: <4407357.lKIgZNIjDk@tommyiv> <e5768eb2-03d5-0c47-5486-209ecd67fb5b@srcbox.net>
MIME-Version: 1.0
Content-Transfer-Encoding: 7Bit
X-OutGoing-Spam-Status: No, score=-1.0
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname - server315.webhostingpad.com
X-AntiAbuse: Original Domain - lists.netservicesgroup.com
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - peterhyman.com
X-Get-Message-Sender-Via: server315.webhostingpad.com: authenticated_id: pete@peterhyman.com
X-Authenticated-Sender: server315.webhostingpad.com: pete@peterhyman.com
X-Source:
X-Source-Args:
X-Source-Dir:
X-Originating-IP: 69.39.232.110
X-Country: code=US country="United States" ip=69.39.232.110
X-Rcpt-To: <gkrellm@lists.netservicesgroup.com>
X-SpamDetect: *************: 13.8 sd=13.8 Close nspam=15 nok=0 1.00 $0.90(X-Phrase:isspam) $0.85(X-Verify-SMTP present) $0.80(X-myrbl:unknown) $0.79(X-Verify-Helo:-ERR) 0.23(X-NotAscii:us-ascii) 0.73(X-Verify-MX present) 0.72(X-Verify-Helo:wrongip) 0.39(X-Country:States) 0.42(dkimok) 0.43(genuine) 0.46(StandardTLD) $0.47(spfpass) $0.48(X-LangGuess:English) SanScore 13.2 13.8
X-NotAscii: charset=us-ascii
X-LangGuess: English
X-Phrase: IsSpam score=1.00
X-Verify-Helo: -ERR wrongip: server315.webhostingpad.com -> 69.65.*.* not in 69.39.232.110
Authentication-Results: mailproc.sbbsnet.net header.from=pete@peterhyman.com; dkim=pass (good signature)
X-Verify-MX: <pete@peterhyman.com> senders ip (ch=69.39.232.110 msg=69.39.232.110, net=69.39.) not in mx data dom=peterhyman.com ipname=server315mail1.webhostingpad.com (69.65.3.245)
X-Encryption: SSL encrypted
X-MyRbl: Color=Unknown ip=69.39.232.110
X-IP-stats: Incoming Last 0, First 70, in=114, out=0, spam=0 ip=69.39.232.110
List-Unsubscribe: <mailto:gkrellm-leave@lists.netservicesgroup.com?subject=unsubscribe>
X-Mailing-List: gkrellm@lists.netservicesgroup.com
List-ID: <gkrellm@lists.netservicesgroup.com>
Precedence: bulk
Reply-To: gkrellm@lists.netservicesgroup.com
On Sunday, October 07, 2018 13:45 you wrote:
> Hi Peter,
>
> On 30/07/2018 15:01, Peter Hyman wrote:
> > gkrellm krell scale for volume sizes is at 100% in some cases. See graphic.
> > This issue appeared after creating some LVM volumes.
> >
> > This patch addresses two issues:
> > 1. changes long long type to unsigned long long since disk block size is always positive.
>
> This would also need type changes for other variables otherwise you're
> comparing values of different signedness which triggers compiler
> warnings, hence I've left that out for now.
The structure members,
gint64 blocks,
bfree,
bavail,
bsize;
part of the FSMon structure in fs.c and the Mount structure in client.c would need adjustment to guint64.
However, there is some inconsistency in client.c
client_fs_line_from_server(gchar *line)
{
GList *list;
Mount *m;
gchar dir[128], dev[64];
gulong blocks, bavail, bfree, bsize;
where gulong is used and not gint64 and later there are assignments from gint64
if (!strcmp(m->directory, dir) && !strcmp(m->device, dev))
{
m->blocks = blocks;
m->bavail = bavail;
m->bfree = bfree;
m->bsize = bsize;
break;
}
So, you're correct, a little bit of work will be necessary to totally clean up the code. In any case, unsigned long or long long is good form for disk sizes.
Luckily, the main issue of not having the right krell values computed is resolved. The rest can be tolerated by compilers!
|