From owner-freebsd-questions@FreeBSD.ORG Wed Jan 14 01:31:33 2015 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id A85A91C0 for ; Wed, 14 Jan 2015 01:31:33 +0000 (UTC) Received: from mail.cyberleo.net (paka.cyberleo.net [216.226.128.180]) by mx1.freebsd.org (Postfix) with ESMTP id 85722B7D for ; Wed, 14 Jan 2015 01:31:32 +0000 (UTC) Received: from [172.16.44.4] (vitani.den.cyberleo.net [216.80.73.130]) by mail.cyberleo.net (Postfix) with ESMTPSA id E078216C72; Tue, 13 Jan 2015 20:21:32 -0500 (EST) Message-ID: <54B5C49B.9030203@cyberleo.net> Date: Tue, 13 Jan 2015 19:21:31 -0600 From: CyberLeo Kitsana User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.8.0 MIME-Version: 1.0 To: Chris Kiakas , freebsd-questions@freebsd.org Subject: Re: Looking for some Documentation in fine-tuning kernel variables on Jails References: <1DC8D2C9-7ABC-4364-973A-E77A9176B81E@lrckinfo.com> In-Reply-To: <1DC8D2C9-7ABC-4364-973A-E77A9176B81E@lrckinfo.com> X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Jan 2015 01:31:33 -0000 On 01/13/2015 03:19 PM, Chris Kiakas wrote: > Hello, > > I a have a system running 8 jails. The jails contain MySQL DBs, Apache and php. On one jail I’m running Redmine and it just started giving me a "stack level too deep” error. I believe that increasing the stack size limit from the current system from 524288 kB to possibly twice the size would resolve the error. I was looking for documentation/how to or possibly a book on tweaking systems and/or jails. > > If someone could just point me in the proper direction it would be much apreciated. Various program limits are usually set in login.conf(5) and should take effect if set in jails as well. If invoking the process interactively, you may use the ulimit(1) command to set the stack size. However, it's probably pretty unlikely that redmine is causing ruby to legitimately use more than 512 megabytes of stack space. If ruby links to libthr, that will limit the size of the initial thread's stack to one or two megabytes; tuning this via ulimit or login.conf will not help, as the initial thread stack size is hardcoded in the library. I would suggest you investigate the backtrace that Ruby provides when SystemStackError is raised, to rule out the possibility of a bug causing infinite recursion. Then you can look into modifying the library to increase the default stack size and see if that helps. If so, it may be further evidence that this should be increased, or at least made tunable. -- Fuzzy love, -CyberLeo Technical Administrator CyberLeo.Net Webhosting http://www.CyberLeo.Net Furry Peace! - http://www.fur.com/peace/