Return-Path: X-Original-To: apmail-lucene-solr-user-archive@minotaur.apache.org Delivered-To: apmail-lucene-solr-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0E077D1EB for ; Mon, 6 Aug 2012 17:48:44 +0000 (UTC) Received: (qmail 4807 invoked by uid 500); 6 Aug 2012 17:48:40 -0000 Delivered-To: apmail-lucene-solr-user-archive@lucene.apache.org Received: (qmail 4767 invoked by uid 500); 6 Aug 2012 17:48:40 -0000 Mailing-List: contact solr-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-user@lucene.apache.org Delivered-To: mailing list solr-user@lucene.apache.org Received: (qmail 4758 invoked by uid 99); 6 Aug 2012 17:48:40 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Aug 2012 17:48:40 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=FSL_RCVD_USER,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of jdrukman@gmail.com designates 209.85.160.176 as permitted sender) Received: from [209.85.160.176] (HELO mail-gh0-f176.google.com) (209.85.160.176) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Aug 2012 17:48:32 +0000 Received: by ghbz10 with SMTP id z10so3272008ghb.35 for ; Mon, 06 Aug 2012 10:48:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=cjiGQucu+vaI5zz2+2IDr4tyRbfzSSKVUIs5r8gw3Fk=; b=OqjP2hV1AmR60bItdglgOaw+MYl/MZlqTTfEAdlOHD0AZ3yWgHFbVwfux6k+gxWRhZ 0InHWphMJUmoB7ThNgRbcQQF+FFc28rJYntqFCuNja1wec+uinzR08SxN0+OYe3uh6vN yOkFH0UjwUUV4Y+FYs5sUKqAXMSx2I6AKCreb4qi6TI6WcYNXeyfoKt6U/NHbKCMyrte LbpxIQ1n3UrdA9W9jkp1Wm6SgNNPF7pDxKP+oq2ghT3evzkqdd7CkMForv13CnJvjxvq HVYrWV6eZL8MT9oCnhBt+ln29ZhATz6HS3q414mtB6t8yfxWZJogR9qKk3yNAzy4i4FA BOTQ== MIME-Version: 1.0 Received: by 10.66.78.9 with SMTP id x9mr19726260paw.84.1344275291572; Mon, 06 Aug 2012 10:48:11 -0700 (PDT) Received: by 10.66.237.41 with HTTP; Mon, 6 Aug 2012 10:48:11 -0700 (PDT) Date: Mon, 6 Aug 2012 10:48:11 -0700 Message-ID: Subject: Running out of memory From: Jon Drukman To: solr-user@lucene.apache.org Content-Type: multipart/alternative; boundary=f46d042e00e33c0b2704c69c7b38 --f46d042e00e33c0b2704c69c7b38 Content-Type: text/plain; charset=ISO-8859-1 Hi there. I am running Solr 1.4.1 on an Amazon EC2 box with 7.5GB of RAM. It was set up about 18 months ago and has been largely trouble-free. Unfortunately, lately it has started to run out of memory pretty much every day. We are seeing SEVERE: java.lang.OutOfMemoryError: Java heap space When that happens, a simple query like "http://localhost:8983/solr/select?q=*:*'" returns nothing. I am starting Solr with the following: /usr/lib/jvm/jre/bin/java -XX:+UseConcMarkSweepGC -Xms1G -Xmx5G -jar start.jar It would be vastly preferable if Solr could just exit when it gets a memory error, because we have it running under daemontools, and that would cause an automatic restart. After restarting, Solr works fine for another 12-18 hours. Not ideal but at least it wouldn't require human intervention to get it going again. What can I do to reduce the memory pressure? Does Solr require the entire index to fit in memory at all times? The on disk size is 15GB. There are 27.5 million documents, but they are all tiny (mostly one line forum comments like "this game is awesome"). We're using Sun openJava SDK 1.6 if that matters. -jsd- --f46d042e00e33c0b2704c69c7b38--