From owner-freebsd-ports@freebsd.org Sat Dec 1 17:43:39 2018 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4CF101322ECB for ; Sat, 1 Dec 2018 17:43:39 +0000 (UTC) (envelope-from list1@gjunka.com) Received: from msa1.earth.yoonka.com (yoonka.com [88.98.225.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "msa1.earth.yoonka.com", Issuer "msa1.earth.yoonka.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id BAFD86D99F for ; Sat, 1 Dec 2018 17:43:38 +0000 (UTC) (envelope-from list1@gjunka.com) Received: from crayon2.yoonka.com (crayon2.yoonka.com [10.70.7.20]) (authenticated bits=0) by msa1.earth.yoonka.com (8.15.2/8.15.2) with ESMTPSA id wB1Hhbl5056095 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NO) for ; Sat, 1 Dec 2018 17:43:37 GMT (envelope-from list1@gjunka.com) Subject: Re: Distributed poudriere To: freebsd-ports@freebsd.org References: <38edd5f9-4a84-a8a6-2439-d54fb826982d@gjunka.com> <2af9f5f8-a109-afb7-68ee-349bd2676dd8@nomadlogic.org> From: Grzegorz Junka Message-ID: <0ab8060f-bf63-6eda-8d1d-8bc2f261527f@gjunka.com> Date: Sat, 1 Dec 2018 17:43:37 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.3.1 MIME-Version: 1.0 In-Reply-To: <2af9f5f8-a109-afb7-68ee-349bd2676dd8@nomadlogic.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-GB-large X-Rspamd-Queue-Id: BAFD86D99F X-Spamd-Result: default: False [-2.13 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; NEURAL_HAM_MEDIUM(-0.99)[-0.988,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:88.98.225.149]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-ports@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.97)[-0.974,0]; DMARC_NA(0.00)[gjunka.com]; NEURAL_SPAM_SHORT(0.16)[0.161,0]; MX_GOOD(-0.01)[cached: gjunka.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; IP_SCORE(-0.02)[country: GB(-0.10)]; ASN(0.00)[asn:56478, ipnet:88.98.192.0/18, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-Rspamd-Server: mx1.freebsd.org X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 01 Dec 2018 17:43:39 -0000 On 30/11/2018 19:31, Pete Wright wrote: > On 11/30/18 9:08 AM, Grzegorz Junka wrote: >> On 29/11/2018 19:12, Grzegorz Junka wrote: >>> Hello, >>> >>> Is it possible to run poudriere in an agent/server setup? Where one >>> central server maintains a distfiles folder for already compiled >>> packages and agents compile packages fetching and installing from >>> the central server dependencies? >>> >> Just to make it more clear, I am asking about the build process. >> Poudriere starts the specified amount of jails to build packages in >> parallel. In each jail it then install dependencies by fetching them >> from the distfiles folder. After the build is done a new package is >> created and uploaded to the distfiles folder to be used by builds >> that require it. >> >> This process is CPU-core-bound, i.e. with 32/64 threads cores it >> can't really build more than 64 packages in parallel. And systems >> with so many cores are really expensive. But the whole process is >> inherently distributed (as long as the amount of packages is big >> enough so that they can be build in parallel). >> >> Being able to build on multiple cheaper systems with less CPU cores >> per system over the network seems like a good idea, no? >> > > haven't fully thought this idea through, but couldn't you achieve this > by mounting the Poudriere 'data' directories as an NFS mountpoint?  > This way each jail would view currently available package metadata and > hopefully avoid doing duplicate work? > > I'm sure there will be racing condition edge cases though which will > bite you since I don't think there is a build job dispatcher/scheduler > available in Poudriere.  So for example you may find yourself in a > situation where multiple jails try building LLVM as it's first package > which wouldn't really be helpful. > I believe poudriere plans what needs to be build before it starts the build in order to detect circular dependencies. I don't think a shared NFS mountpoint would be of any use. There ought to be a single scheduler which deletes the outdated packages and plans what needs to be build, but then instead distributing the build across jails on the same system, it would have to be able to distribute the workload across multiple systems. Thanks for confirming it's not available yet. Would be a nice and useful addition. I should start learning poudriere code perhaps to see if this is something I could do. Regards GrzegorzJ