From owner-freebsd-hackers Sat Jan 12 14:25:42 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from obsecurity.dyndns.org (adsl-63-207-60-75.dsl.lsan03.pacbell.net [63.207.60.75]) by hub.freebsd.org (Postfix) with ESMTP id 8812C37B41A for ; Sat, 12 Jan 2002 14:25:35 -0800 (PST) Received: by obsecurity.dyndns.org (Postfix, from userid 1000) id 2579866D43; Sat, 12 Jan 2002 14:25:35 -0800 (PST) Date: Sat, 12 Jan 2002 14:25:35 -0800 From: Kris Kennaway To: Nate Williams Cc: hackers@FreeBSD.org Subject: Re: Amount of free memory available in system? Message-ID: <20020112142534.D40866@xor.obsecurity.org> References: <15424.32963.768829.892783@caddis.yogotech.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-md5; protocol="application/pgp-signature"; boundary="HWvPVVuAAfuRc6SZ" Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <15424.32963.768829.892783@caddis.yogotech.com>; from nate@yogotech.com on Sat, Jan 12, 2002 at 11:30:27AM -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --HWvPVVuAAfuRc6SZ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Jan 12, 2002 at 11:30:27AM -0700, Nate Williams wrote: > Is there a simple sysctl or a command line utility I can use to > determine how much free memory is available in a system? >=20 > I've got an embedded application that has *very* limited memory, and I > was trying to figure out how much memory was available for the userland > applications. >=20 > 'top' has something, as well as 'vmstat'. Unfortunately, because of the > limited amount of disk space available on this box, I don't have access > to either one of those. >=20 > Is there a sysctl I can use to determine how much free memory is > available on the box? Why not look how top and vmstat calculate it and do that in your code. Kris --HWvPVVuAAfuRc6SZ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.6 (FreeBSD) Comment: For info see http://www.gnupg.org iD8DBQE8QLfeWry0BWjoQKURAmMAAJsEJ29Pcsm1DRtK2nY2mJYG4k0xzgCfcjF0 wemE/ltrP5eEmK2YJ76ITbE= =57s0 -----END PGP SIGNATURE----- --HWvPVVuAAfuRc6SZ-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message