xymon

Check-in [da5e523b57]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:BSD client fixes, from Mark Felder git-svn-id: http://svn.code.sf.net/p/xymon/code/branches/4.3.19@7505 44351d6e-118b-4698-b696-ce33095ecaa4
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk | origin/4.3.19
Files: files | file ages | folders
SHA3-256: da5e523b572bef25690c9d09edd4142ba3e4e363f29ad36a4959d0e96d6af76d
User & Date: jccleaver@users.sf.net 2015-02-08 03:54:56
Context
2015-02-10
13:57
dbgprintf macro optimization; logging tuning, print usecs; add logprintf stub git-svn-id: http://svn.code.sf.net/p/xymon/code/branches/4.3.19@7506 44351d6e-118b-4698-b696-ce33095ecaa4 check-in: c1798f3557 user: jccleaver@users.sf.net tags: trunk, origin/4.3.19
2015-02-08
03:54
BSD client fixes, from Mark Felder git-svn-id: http://svn.code.sf.net/p/xymon/code/branches/4.3.19@7505 44351d6e-118b-4698-b696-ce33095ecaa4 check-in: da5e523b57 user: jccleaver@users.sf.net tags: trunk, origin/4.3.19
02:21
Backfix from trunk xymonnet2 - /etc/services IANA port 1984 is 'bb' git-svn-id: http://svn.code.sf.net/p/xymon/code/branches/4.3.19@7504 44351d6e-118b-4698-b696-ce33095ecaa4 check-in: 69957db8da user: jccleaver@users.sf.net tags: trunk, origin/4.3.19
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to client/freebsd-meminfo.c.

40
41
42
43
44
45
46
47
48
49
	if (result != 0) return 1;

	len = sizeof(vmdata);
	result = sysctl(vm_vmtotal, sizeof(vm_vmtotal) / sizeof(*vm_vmtotal), &vmdata, &len, NULL, 0);

	// printf("Pagesize:%d\n", pagesize);
	printf("Total:%lu\n", (physmem / (1024 * 1024)));
	printf("Free:%lu\n", (pagesize / 1024)*(vmdata.t_free / 1024));
}








|


40
41
42
43
44
45
46
47
48
49
	if (result != 0) return 1;

	len = sizeof(vmdata);
	result = sysctl(vm_vmtotal, sizeof(vm_vmtotal) / sizeof(*vm_vmtotal), &vmdata, &len, NULL, 0);

	// printf("Pagesize:%d\n", pagesize);
	printf("Total:%lu\n", (physmem / (1024 * 1024)));
	printf("Free:%d\n", (pagesize / 1024)*(vmdata.t_free / 1024));
}

Changes to client/openbsd-meminfo.c.

11
12
13
14
15
16
17

18
19
20
21
22
23
24
25
26
27
28
29
30
31
32

static char rcsid[] = "$Id$";

#include <sys/param.h>
#include <sys/types.h>
#include <sys/sysctl.h>
#include <sys/swap.h>

#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
	int hw_physmem[] = { CTL_HW, HW_PHYSMEM };
	int physmem;

	int hw_pagesize[] = { CTL_HW, HW_PAGESIZE };
	int pagesize;

	int vm_vmtotal[] = { CTL_VM, VM_METER };
	struct vmtotal vmdata;








>







|







11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33

static char rcsid[] = "$Id$";

#include <sys/param.h>
#include <sys/types.h>
#include <sys/sysctl.h>
#include <sys/swap.h>
#include <sys/vmmeter.h>
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>

int main(int argc, char *argv[])
{
	int hw_physmem[] = { CTL_HW, HW_PHYSMEM };
	unsigned int physmem;

	int hw_pagesize[] = { CTL_HW, HW_PAGESIZE };
	int pagesize;

	int vm_vmtotal[] = { CTL_VM, VM_METER };
	struct vmtotal vmdata;