Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Nov 2006 23:41:23 -0500
From:      Kris Kennaway <kris@obsecurity.org>
To:        "van Osnabrugge, Sean" <svanosnabrugge@osler.com>
Cc:        freebsd-stable@freebsd.org
Subject:   Re: grep: memory exhausted
Message-ID:  <20061130044123.GA19761@xor.obsecurity.org>
In-Reply-To: <7883F37393F1D44990888174C2E5E91222666A@TSV-EXCHANGE.ohhllp.com>
References:  <7883F37393F1D44990888174C2E5E91222666A@TSV-EXCHANGE.ohhllp.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--TB36FDmn/VVEgNH/
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Wed, Nov 29, 2006 at 03:10:33PM -0500, van Osnabrugge, Sean wrote:
> Hi there,
>=20
> =20
>=20
> I am running a fresh install of FreeBSD-6.1-Stable as a guest OS in
> VMWare 1.0.1 with 1 GB of RAM.
>=20
> =20
>=20
> Whenever I try to grep a large text file (400 MB+), grep terminates with
> "grep: memory exhausted"
>=20
> =20
>=20
> I have tried piping grep (cat "file" | grep "search term")
>=20
> I have tried it with -line-buffered
>=20
> =20
>=20
> ulimit -a show:
>=20
> core file size        (blocks, -c) unlimited
>=20
> data seg size         (kbytes, -d) 524288

Try increasing this.  I think grep mmaps the file, so the large file
could be exceeding your limit.

Kris
--TB36FDmn/VVEgNH/
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (FreeBSD)

iD8DBQFFbmDzWry0BWjoQKURAq8kAJ4i6zNiXPiI/ILZuOSdWL1ATjaeNwCfbaQr
roqJFwQNau2hGQfa5AD4b8g=
=wVzX
-----END PGP SIGNATURE-----

--TB36FDmn/VVEgNH/--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061130044123.GA19761>