From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 7182796543154454528 X-Received: by 2002:a25:d610:0:b0:7cb:fa3a:23e9 with SMTP id n16-20020a25d610000000b007cbfa3a23e9mr1215666ybg.250.1674145844940; Thu, 19 Jan 2023 08:30:44 -0800 (PST) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a25:bf83:0:b0:7fe:3f01:167e with SMTP id l3-20020a25bf83000000b007fe3f01167els874499ybk.2.-pod-prod-gmail; Thu, 19 Jan 2023 08:30:44 -0800 (PST) X-Google-Smtp-Source: AMrXdXvLo+Au598y+vl3VcBffO1uTi57k3S0ITMxnc8hNRapFI5m0Ww+kLQCXISCZdi1wQULUfcp X-Received: by 2002:a5b:381:0:b0:7d9:1fa7:9c2c with SMTP id k1-20020a5b0381000000b007d91fa79c2cmr8826078ybp.45.1674145844199; Thu, 19 Jan 2023 08:30:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1674145844; cv=none; d=google.com; s=arc-20160816; b=DGpWGxGdSPApQpTFaMrO1mz1DZhzLIj7UVt+25uxXWqd2i/n6LmP2nNoAfIn8hFHxi B/Hlbh9moBkPhJD9U9Ab1yhetn9llv7ag4so5F+SikmA0z2G7KdTbF82ClQNCJSm4ZBq dtF8H/Ow4LVSZj0ZdF/YekB0ZK5VRTdaTqkgSS/EcwyZzECzHKUjgg4RGw7XiCOgGYgx HpwzGoEAOf6zIEZseJF7yjMx4wzwnNjeKjVHjRWkyFnXy5/ql7AgO0meLmbLq+pfUsPy /GSgu9xh7AZh6sgu070l6r6G5LFaOfC/TiMEfF2NHTF/mIJQNwlNbvSq3tLpujheEUkS L3bw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:dkim-signature; bh=wnOYv1FLwk9GOyb2bkCzHC78cA5WvIIAXtjX2VKWJLQ=; b=AZQeu4wVTuhW7Gm/Lb7ZIAHzSJnwtEN8U7HKN/ZvjxwkqhvslgzeZbnrxDCWhrm5im M+JOnqEweqgqRA9/XigZg4zPdaba4WVO2yWxnFLgBhPe9qhklEvNuDhMSflylqgRqe3j MTW6UmXAnZe3SMxcVdEN+Jr2iF2e1EGE6E4eICWqqg/3MD09LTOQXo+rshIQHGqq9+E0 5ZML1d1fFvsvpOxCW0LsiGsmuUlYH9h6/bOteY98AcnLKKDdB+4rbQbdbypc3hVVS7Zl Kct7BBiysNnsx3xn0XVywVStzKq1vvM0TIZaYfw+nMMKMfoHkp3kQfp6WA4ui0ZIlrAV OqaA== ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=gCPAHwmr; spf=pass (google.com: domain of roberto.foglietta@gmail.com designates 2607:f8b0:4864:20::730 as permitted sender) smtp.mailfrom=roberto.foglietta@gmail.com; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail-qk1-x730.google.com (mail-qk1-x730.google.com. [2607:f8b0:4864:20::730]) by gmr-mx.google.com with ESMTPS id 201-20020a2505d2000000b007ddb8337f72si5595ybf.1.2023.01.19.08.30.44 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 19 Jan 2023 08:30:44 -0800 (PST) Received-SPF: pass (google.com: domain of roberto.foglietta@gmail.com designates 2607:f8b0:4864:20::730 as permitted sender) client-ip=2607:f8b0:4864:20::730; Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=gCPAHwmr; spf=pass (google.com: domain of roberto.foglietta@gmail.com designates 2607:f8b0:4864:20::730 as permitted sender) smtp.mailfrom=roberto.foglietta@gmail.com; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: by mail-qk1-x730.google.com with SMTP id l1so1426268qkg.11 for ; Thu, 19 Jan 2023 08:30:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=wnOYv1FLwk9GOyb2bkCzHC78cA5WvIIAXtjX2VKWJLQ=; b=gCPAHwmr6MimgsjSq8n/rLWbIshmuzDVCh2tlgMJLhtBzrbH6x5JHe0ws04OivSfL4 wgRG6NRJ6IFOsmG3FIvwomS+eiv43H/aOXiSxfRcC97Qs4O502tlEdBjOKsMZ8lHabQz zA1bjB2ApuBTrO2MAHtrVjlrcHvl5LKXMdqVZuo5G56NBciazWUeN0fS5F3QaALEN9et LgRwkIm67q/z08D0TpHGzu2tueJSjL+YouvP1dQaaAPKgC6NAFcK51wv2c6lKw5SFht8 Utu7nsjjjAPsgEF1PBj6nMQRsnWdBsIbj716SorMnncI25A3ib8DAsjEDYOxGZkuipTJ Mlmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=wnOYv1FLwk9GOyb2bkCzHC78cA5WvIIAXtjX2VKWJLQ=; b=oi046gjp9mGt/bq+tjIsv22MKIah2DRr0f4fUcIxYIc9P7UDt11wMUGoCwZs9x61bY byZGOdPRBzQqd9SdqkJWvaaZ7ISopfMM3wuySdyjKGs5iWkF7o+j7OhxbnDJ3J4gQUgh fAeDRgvlkKRBr7+gGyPaBEvCAMgq+228awwUtu3O0s/slVRBoyl4f3xpiiVMBZCg1fKI d3/5PxI64xkr8Kf7PbVvMFWlU1ua3nvn+1qAVDP+XUzm23FMs2BlRaRksOtBy/YU1e3l 51pRMuB0MBIjPEq4aw6H9Wg6mYgDtQcJjcgy0MA0ZAOL62JToi6KIvHb6IPBCWyQJELK eICA== X-Gm-Message-State: AFqh2kpnt/FFhJxCD4zgvP/+0GENX+dV/KNefG3MmkOafNcInyGz6DQ3 Cu9bmUD5G+chbYi0U7JsCUh16Tjx93wnRm/RExxk7UqzLN8q X-Received: by 2002:a05:620a:219b:b0:705:e0a8:1b03 with SMTP id g27-20020a05620a219b00b00705e0a81b03mr430045qka.119.1674145843776; Thu, 19 Jan 2023 08:30:43 -0800 (PST) MIME-Version: 1.0 References: <20230106064809.10412-1-ubely@ilbers.de> <00ca12addc6e3b93aeca6127124cfc2f0a1aabf2.camel@siemens.com> <6842478.jJDZkT8p0M@home> <6100573.eO5KgaWL5Y@home> In-Reply-To: From: "Roberto A. Foglietta" Date: Thu, 19 Jan 2023 17:30:07 +0100 Message-ID: Subject: Re: [PATCH v2 0/3] Improving apt cache To: Uladzimir Bely Cc: "isar-users@googlegroups.com" , "Moessbauer, Felix" Content-Type: multipart/alternative; boundary="00000000000052125e05f2a0742d" X-TUID: IJZ8cUi935Yw --00000000000052125e05f2a0742d Content-Type: text/plain; charset="UTF-8" On Thu, 19 Jan 2023 at 15:52, Roberto A. Foglietta < roberto.foglietta@gmail.com> wrote: > > On Thu, 19 Jan 2023 at 08:36, Uladzimir Bely wrote: > >> >> I got time to get back to this patches and checked this moment. And it >> really >> does not work as I expected. >> >> Original patch includes the following: >> >> - --chroot-setup-commands="cp -n --no-preserve=owner >> ${ext_deb_dir}/ >> *.deb -t ${deb_dir}/ || :" \ >> + --chroot-setup-commands="ln -Pf ${ext_deb_dir}/*.deb -t >> ${deb_dir}/ >> 2>/dev/null || :" \ >> >> This results to to failing "ReproTest" in CI with the following error >> (for >> libhello, for example): >> >> sbuild-build-depends-dose3-dummy:armhf : Depends: dose-distcheck:amd64 >> but it >> is not installable >> E: Unable to correct problems, you have held broken packages. >> >> To debug it, I removed `2>/dev/null` and found, that hardlinks simply >> don't >> work and the following errors are now seen earlier: >> >> ln: failed to create hard link >> '/var/cache/apt/archives/adduser_3.118_all.deb' >> => '/home/builder/libhello/rootfs/var/cache/apt/archives/ >> adduser_3.118_all.deb': Invalid cross-device link >> ... #tons of similar errors... >> ln: failed to create hard link '/var/cache/apt/archives/ >> zlib1g_1%3a1.2.11.dfsg-2+deb11u2_mipsel.deb' => '/home/builder/libhello/ >> rootfs/var/cache/apt/archives/zlib1g_1%3a1.2.11.dfsg-2+deb11u2_mipsel.deb': >> >> Invalid cross-device link >> >> I: Finished running 'ln -Pf /home/builder/libhello/rootfs/var/cache/apt/ >> archives/*.deb -t /var/cache/apt/archives/ || :'. >> >> So, it works for network builds (when missing packages always can be >> downloaded by apt), but it fails for local builds from apt-cache (when, >> at >> first network build, sbuild dependencies are simply not exported to >> download >> directory due to non-working hardlinks, plus with hidden stderr) >> > Yes, I confirm that it is possible to do sbuild without using neither cp nor ln, using an elegant solution. So, whatever the problem was - it is not a problem anymore. Best, R- --00000000000052125e05f2a0742d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Thu, 19 Jan 2023 at 15:52, Roberto A. = Foglietta <roberto.foglie= tta@gmail.com> wrote:
<= br>
O= n Thu, 19 Jan 2023 at 08:36, Uladzimir Bely <ubely@ilbers.de> wrote:

I got time to get back to this patches and checked this moment. And it real= ly
does not work as I expected.

Original patch includes the following:

-=C2=A0 =C2=A0 =C2=A0 =C2=A0 --chroot-setup-commands=3D"cp -n --no-pre= serve=3Downer ${ext_deb_dir}/
*.deb -t ${deb_dir}/ || :" \
+=C2=A0 =C2=A0 =C2=A0 =C2=A0 --chroot-setup-commands=3D"ln -Pf ${ext_d= eb_dir}/*.deb -t ${deb_dir}/
2>/dev/null || :" \

This results to to failing "ReproTest" in CI with the following e= rror (for
libhello, for example):

sbuild-build-depends-dose3-dummy:armhf : Depends: dose-distcheck:amd64 but = it
is not installable
E: Unable to correct problems, you have held broken packages.

To debug it, I removed `2>/dev/null` and found, that hardlinks simply do= n't
work and the following errors are now seen earlier:

ln: failed to create hard link '/var/cache/apt/archives/adduser_3.118_a= ll.deb'
=3D> '/home/builder/libhello/rootfs/var/cache/apt/archives/
adduser_3.118_all.deb': Invalid cross-device link
... #tons of similar errors...
ln: failed to create hard link '/var/cache/apt/archives/
zlib1g_1%3a1.2.11.dfsg-2+deb11u2_mipsel.deb' =3D> '/home/builder= /libhello/
rootfs/var/cache/apt/archives/zlib1g_1%3a1.2.11.dfsg-2+deb11u2_mipsel.deb&#= 39;:
Invalid cross-device link

I: Finished running 'ln -Pf /home/builder/libhello/rootfs/var/cache/apt= /
archives/*.deb -t /var/cache/apt/archives/ || :'.

So, it works for network builds (when missing packages always can be
downloaded by apt), but it fails for local builds from apt-cache (when, at =
first network build, sbuild dependencies are simply not exported to downloa= d
directory due to non-working hardlinks, plus with hidden stderr)


Yes, I co= nfirm that it is possible to do sbuild without using neither cp nor ln, usi= ng an elegant solution.

So, whatever the problem w= as - it is not a problem anymore.
=C2=A0
Best, R-

--00000000000052125e05f2a0742d--