From owner-freebsd-hackers@FreeBSD.ORG Tue Jun 12 23:02:17 2012 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3CC8A106566C for ; Tue, 12 Jun 2012 23:02:17 +0000 (UTC) (envelope-from ryao@gentoo.org) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by mx1.freebsd.org (Postfix) with ESMTP id 1E0208FC0A for ; Tue, 12 Jun 2012 23:02:17 +0000 (UTC) Received: from [192.168.1.2] (pool-108-46-203-161.nycmny.fios.verizon.net [108.46.203.161]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: ryao) by smtp.gentoo.org (Postfix) with ESMTPSA id A2AA71B402C for ; Tue, 12 Jun 2012 23:02:11 +0000 (UTC) Message-ID: <4FD7CA24.6080405@gentoo.org> Date: Tue, 12 Jun 2012 19:00:52 -0400 From: Richard Yao User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.4) Gecko/20120430 Thunderbird/10.0.4 MIME-Version: 1.0 To: freebsd-hackers@freebsd.org References: <4FD66F7E.2060404@brandonfa.lk> <71dc991c8d1b4d2c91ff942fc5f8f340@HUBCAS2.cs.stonybrook.edu> In-Reply-To: <71dc991c8d1b4d2c91ff942fc5f8f340@HUBCAS2.cs.stonybrook.edu> X-Enigmail-Version: 1.3.5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Wed, 13 Jun 2012 01:15:41 +0000 Subject: Re: FreeBSD Boot Times X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 12 Jun 2012 23:02:17 -0000 On 06/11/12 18:51, Garrett Cooper wrote: > On Mon, Jun 11, 2012 at 3:21 PM, Brandon Falk wrote: >> Greetings, >> >> I was just wondering what it is that FreeBSD does that makes it take so long >> to boot. Booting into Ubuntu minimal or my own custom Linux distro, >> literally takes 0.5-2 seconds to boot up to shell, where FreeBSD takes about >> 10-20 seconds. I'm not sure if anything could be parallelized in the boot >> process, but Linux somehow manages to do it. The Ubuntu install I do pretty >> much consists of a shell and developers tools, but it still has a generic >> kernel. There must be some sort of polling done in the FreeBSD boot process >> that could be parallelized or eliminated. >> >> Anyone have any suggestions? >> >> Note: This isn't really an issue, moreso a curiosity. > The single process nature of rc is a big part of the problem, as > is the single AP bootup of FreeBSD right before multiuser mode. There > are a number of threads that discuss this (look for parallel rc bootup > or something like that in the current, hacker, and rc archives -- the > most recent discussion was probably 6~9 months ago). > Given past experience, a big part of getting past the parallelized > rc mess would be to make services fail/wait gracefully for all their > resources to come up before proceeding. It's not easy, but it's > possible with enough resources. > HTH, > -Garrett > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" Gentoo FreeBSD shares OpenRC with Gentoo Linux. OpenRC is a BSD 2-clause licensed System V init system replacement that supports parallel boot. Its boot performance is competitive with systemd and Ubuntu's upstart. If FreeBSD's init system is serializing the boot process, it might be worthwhile to consider importing OpenRC.