From cjohnson@neunacht.netgsi.com  Sat Feb  6 16:02:39 1999
Received: from neunacht.netgsi.com (neunacht.netgsi.com [192.55.203.174])
          by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id QAA09326
          for <FreeBSD-gnats-submit@freebsd.org>; Sat, 6 Feb 1999 16:02:38 -0800 (PST)
          (envelope-from cjohnson@neunacht.netgsi.com)
Received: (from cjohnson@localhost)
	by neunacht.netgsi.com (8.9.2/8.9.2) id TAA42301;
	Sat, 6 Feb 1999 19:02:30 -0500 (EST)
	(envelope-from cjohnson)
Message-Id: <199902070002.TAA42301@neunacht.netgsi.com>
Date: Sat, 6 Feb 1999 19:02:30 -0500 (EST)
From: "Christopher T. Johnson" <cjohnson@neunacht.netgsi.com>
Reply-To: cjohnson@neunacht.netgsi.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: vmstat reports bad AVM values
X-Send-Pr-Version: 3.2

>Number:         9935
>Category:       kern
>Synopsis:       vmstat reprots bad AVM values
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Feb  6 16:10:01 PST 1999
>Closed-Date:    Sat Jun 9 17:59:36 PDT 2001
>Last-Modified:  Sat Jun 09 18:02:36 PDT 2001
>Originator:     Christopher T. Johnson
>Release:        FreeBSD 3.0-STABLE i386
>Organization:
NetGSI, Inc
>Environment:

	FreeBSD 3.0-STABLE i386 as of Feb 5, 1999
	Mutliple machines

>Description:

	AVM sizes are being reported badly.  If vmstat is run just after booting
	values are reasonable, but after a large memory process is started,
	avm goes wild.
vmstat -c2 5
procs      memory     page                   disks        faults      cpu
r b w     avm   fre  flt  re  pi  po  fr  sr fd0 wd0 da0   in   sy  cs us sy id
0 0 0 3688664  7128   10   0   0   0  10   2   0   0   0  235   94  10 14  1 86
0 0 0 3688664  7128    1   0   0   0   0   0   0   0   0  231    9   4  0  0 100

A check of the values returned by sysctl are strange:
vm.vmmeter: Format:S,vmtotal Length:48 Dump:
0x0200		t_rq
  0000		t_dw
  0000		t_pw
  0b00		t_sl
  0000		t_sw
  0000 (Fill, not used)
  6a4e1180	t_vm
  41140e00	t_avm
  e3170000	t_rm
  08050000	t_arm
  dd0b0000	t_vmshr
  f8020000	t_avmshr
  78030000	t_rmshr
  54010000	t_armshr
  91060000	t_free

given that I only have 192M of swap or so and 32M of real memory, the
value of t_vm and t_avm seem more than a little large.

Device      1K-blocks     Used    Avail Capacity  Type
/dev/da0s1b     65536    14372    51036    22%    Interleaved
/dev/wd0s1b    131072    14220   116724    11%    Interleaved
Total          196352    28592   167760    15%

This repeats on another machine running the same STABLE.


>How-To-Repeat:

boot system
login
vmstat -c2 5
startx	(I have a 4MB board and run in 24bit mode at 1280@1024)
vmstat -c2 5


>Fix:
	
	

>Release-Note:
>Audit-Trail:

From: Cy Schubert - BCSC Open Systems Group <cys@wlc.com>
To: freebsd-gnats-submit@freebsd.org, cjohnson@neunacht.netgsi.com
Cc: cschuber@uumail.gov.bc.ca, cy@uumail.gov.bc.ca
Subject: Re: kern/9935: vmstat reprots bad AVM values
Date: Thu, 25 Mar 1999 10:31:18 -0800

 I have the same problem on a 3.1R system with an S3 card with 4MB of
 memory.  What is strange is that another system with a Mach64 card with
 4MB of memory does not exhibit this problem.  I have a hunch that
 systems that exhibit this problem also may have a problem running
 Netscape and displaying it to a local Xserver, e.g. Netscape loops with
 signal 8, 14, gettimeofday(), loop again.
 
 I run the Xserver using xdm.  If noone is logged in via xdm, the AVM
 looks "normal".  If I log in using Xsession the problem exists.  If I
 log by htting ctrl-f1 instead of enter on the xdm login screen the
 problem does not appear.  My .xsession at work (this system doesn't
 exhibit the problem) issues exec $WINDOWMANAGER while (going from
 memory) I do something fancier at home (which has the problem).  This
 angle might look promising and I will investigate it further.  
 
 -- 
 Regards,                       Phone:  (250)387-8437
 Cy Schubert                      Fax:  (250)387-5766
 Open Systems Group          Internet:  cschuber@uumail.gov.bc.ca
 ITSD                                   Cy.Schubert@gems8.gov.bc.ca
 Government of BC
 
State-Changed-From-To: open->closed 
State-Changed-By: dd 
State-Changed-When: Sat Jun 9 17:59:36 PDT 2001 
State-Changed-Why:  
There have been many changes here since 3.0.  If this is still a problem, 
please file another PR. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=9935 
>Unformatted:
