From owner-freebsd-current@freebsd.org Fri Dec 15 19:21:08 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id AC269E89FCD for ; Fri, 15 Dec 2017 19:21:08 +0000 (UTC) (envelope-from wschnr@googlemail.com) Received: from mail-yb0-x22f.google.com (mail-yb0-x22f.google.com [IPv6:2607:f8b0:4002:c09::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5CF1D281F; Fri, 15 Dec 2017 19:21:08 +0000 (UTC) (envelope-from wschnr@googlemail.com) Received: by mail-yb0-x22f.google.com with SMTP id h202so6051022ybg.10; Fri, 15 Dec 2017 11:21:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=B7pEDrcHYb/SJ6L+niknjC2bPvPOkEIyH6d7tyWdnc4=; b=J+7n7CBAlrCyJD3mGyg4Uf2BJT9Smfma1VJh4/e4crXwKh3M87CEzPEBTu/KjkwZU+ UwqWetxF6ut2CjRQyu7Z1C4SNhgCRdDfqxmXCPByI/rFKtCzqat94orDnEvu1uwOBW6E wxAAWe0zmr148AILILmTqZwMenYXSl0F7hnhGvzopgtvUvDoovKlu7/3aSvrTjrW9M6z om9dhp5Fgfum2nbwcuBb0yUkq1EyY4APvrBAkyAxwzLtGURhqjVtWeZCTZL4+dptABpM eJbsoFQ5VdOb3qiakn+dwqY9RSFFqTgu+rdmmQDhwVAPc/1UuXpdN2WcdTs/zKOoSr6C O1LQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=B7pEDrcHYb/SJ6L+niknjC2bPvPOkEIyH6d7tyWdnc4=; b=J+cvfBDGwu43cUqH4x3xVyqn5ua0Le6IlN14nWYqnjGfvdk79ItGZUynRlmgMe05p5 uCMOd3NrqcaLP1+Wk+nLIP+tjvgoySeXup1LvjHKzswXSB1JoTFVvsQ/bmkomckVbTio 8FvBXsEX47rAq+AR7eTuHCU7zRWLVU+E+QXOKvYCWrJMuSL/48q5KQ7Kf7Lh5hwi+Jbc jQw60OgbbwciCth6mLNk8ZXbNx1Y8a+vSTJVxG3TEKTCDBQ+Mx92WFyeXUk1hcHNDOS1 Py3p6uoFoHoIR0rRNEqdcMQ7paq1hjSRKZCAmJ7knZ3pBQE7tt3/bzgL1A/w8bBwhVtn c0MA== X-Gm-Message-State: AKGB3mIcmB71EoP5pWGbmXfRZvSbSAP6XZdJO7GCLPZtfwdXqeWV7/DT hRGfWbmUgM1s3YylOjdePA0y/I1k9azO86w0e4JETw== X-Google-Smtp-Source: ACJfBovWOYrZxrPqp2vwdmGvPfLofeChrpEAPJvXgk9KVNQF6BF6/GQ3sbT+Oanaiygx/UiYK7OQhhzckFGiQ/xyhp4= X-Received: by 10.37.113.87 with SMTP id m84mr7972957ybc.201.1513365667486; Fri, 15 Dec 2017 11:21:07 -0800 (PST) MIME-Version: 1.0 Sender: wschnr@googlemail.com Received: by 10.37.9.80 with HTTP; Fri, 15 Dec 2017 11:20:52 -0800 (PST) In-Reply-To: <20171215183928.GO2272@kib.kiev.ua> References: <20171215120243.GB1179@albert.catwhisker.org> <20171215183928.GO2272@kib.kiev.ua> From: Wolfram Schneider Date: Fri, 15 Dec 2017 20:20:52 +0100 X-Google-Sender-Auth: -QzsgY-eytaj74LZw4bFaczVLgY Message-ID: Subject: Re: /usr/obj is 11GB huge on FreeBSD 12-current To: Konstantin Belousov , Wolfram Schneider Cc: David Wolfskill , freebsd-current Content-Type: text/plain; charset="UTF-8" X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Dec 2017 19:21:08 -0000 On 15 December 2017 at 19:39, Konstantin Belousov wrote: > On Fri, Dec 15, 2017 at 06:38:48PM +0100, Wolfram Schneider wrote: >> On 15 December 2017 at 17:51, Wolfram Schneider wrote: >> > On 15 December 2017 at 13:02, David Wolfskill wrote: >> >> On Fri, Dec 15, 2017 at 10:12:09AM +0100, Wolfram Schneider wrote: >> >>> Hi, >> >>> >> >>> I upgraded a machine from 11-stable to 12-current. The /usr/obj tree >> >>> is now 11GB huge: >> >>> >> >>> FreeBSD 12-current >> >>> $ du -hs /usr/obj >> >>> 11G /usr/obj >> >>> >> >>> on FreeBSD 11-stable it was less the size: >> >>> $ du -hs /usr/obj >> >>> 5.6G /usr/obj >> >>> >> >>> this is a problem when you have a small VM with 20GB disk space or less. >> >>> >> >>> Is there a way to use less /usr/obj disk space during build? I know >> >>> that we have to do some bootstrapping for newer compiler tools, but >> >>> does we need to keep all temp files during the build? >> >> >> >> There was a change near the beginning of November; please see UPDATING >> >> entry 20171101 -- you probably have several no-longer-used >> >> subdirectories under /usr/obj/usr/src/. >> >> >> >> Once those are cleared out, my experience (tracking stable/11 & head in >> >> different slices on the same machines) is that stbale/11 is using about >> >> 5.0G, while head uses about 6.1G. >> > >> > I think the suspect directories are "tmp" and "obj-lib32", together >> > they are 4.1GB huge. >> > >> > I will run a build of current again with a clean obj tree (-current on >> > a recent -current). Let's see. >> >> I run a test on universe12b (FreeBSD 12.0-CURRENT #0 r325426: Sun Nov >> 5) with an empty obj directory. >> >> `make buildworld' creates 9.7GB of obj data. After running `make >> buildkernel' it will grow to 12GB. This is on a ZFS filesystem (my >> original report was on UFS) > > Most likely reason of the bump is generation of debugging data, turned on > for 12. Another not usable thing to disable are tests and profile libraries. > Put the following into /etc/src.conf: > WITHOUT_PROFILE=yes > WITHOUT_DEBUG_FILES=yes > WITHOUT_TESTS=yes Hi Konstantin, I tried these 3 variables and the results looks much better, down to 5.1GB from 12GB. Many thanks! $ du -hs obj* 12G obj-debug 5.1G obj-nodebug -Wolfram -- Wolfram Schneider https://wolfram.schneider.org