OPNsense Forum

English Forums => Development and Code Review => Topic started by: notmks on December 12, 2021, 08:10:12 am

Title: 21.7 build fails due to integrity issues of ports
Post by: notmks on December 12, 2021, 08:10:12 am
Hello,

I have been trying to build OPNSense 21.7 for past one week and having issues, my build fails due to ports integrity issues, Till about 2~3 days ago it was failing due to 2 ports
security/vaults
sysutils/beat7
I wasn't able to find much on it as I checked Nightly build logs by Franco and wasn't able to find much, so I disabled it and started another set of builds now it started to fail on 2 new ports:
dns/bind916
net-mgmt/telegraf
Reason is same Integrity issues with the build and the build exits with code(1).

I am trying to build a customised dvd image.(Haven't made any changes other than www images)

Has anyone also faced these issues, if yes how were you able to overcome them.
I am using FreebSD 12.1 with pkg version 1.16.3
Appreciate all the help.

cheers
Title: Re: 21.7 build fails due to integrity issues of ports
Post by: notmks on December 12, 2021, 08:28:49 am
Output of log for security/vault build:
Update 1: sysutils/beat7 build fails as the security/vault build is failing, implying that beat7 is dependant on vault to build


Code: [Select]
+ generate_signature /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zerotier.txz
+ /usr/tools/scripts/pkg_fingerprint.sh /usr/tools/config/21.7/repo.pub
+ [ -n '' ]
+ rm -f /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zerotier.txz.sig
+ pkg info -F /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/All/zip-3.0_1.txz
+ grep ^Name
+ awk '{ print $3; }'
+ PKGINFO=zip
+ cd /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest
+ ln -sfn ../All/zip-3.0_1.txz zip.txz
+ generate_signature /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zip.txz
+ /usr/tools/scripts/pkg_fingerprint.sh /usr/tools/config/21.7/repo.pub
+ [ -n '' ]
+ rm -f /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zip.txz.sig
+ pkg info -F /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/All/zstd-1.5.0.txz
+ grep ^Name
+ awk '{ print $3; }'
+ PKGINFO=zstd
+ cd /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest
+ ln -sfn ../All/zstd-1.5.0.txz zstd.txz
+ generate_signature /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zstd.txz
+ /usr/tools/scripts/pkg_fingerprint.sh /usr/tools/config/21.7/repo.pub
+ [ -n '' ]
+ rm -f /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/Latest/zstd.txz.sig
+ pkg repo /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/
Creating repository in /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new/: 100%
Packing files for repository: 100%
+ echo FreeBSD:12:amd64
+ sh ./clean.sh packages
>>> Running build step: clean
>>> Passing arguments: packages
>>> Removing packages set
+ PACKAGEVER=21.7.6_133-OpenSSL-amd64
+ PACKAGESET=/usr/local/opnsense/build/21.7/amd64/sets/packages-21.7.6_133-OpenSSL-amd64.tar
+ echo -n '>>> Creating package mirror set for 21.7.6_133-OpenSSL-amd64... '
>>> Creating package mirror set for 21.7.6_133-OpenSSL-amd64... + tar -C /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-new -cf /usr/local/opnsense/build/21.7/amd64/sets/packages-21.7.6_133-OpenSSL-amd64.tar .
+ echo done
done
+ generate_signature /usr/local/opnsense/build/21.7/amd64/sets/packages-21.7.6_133-OpenSSL-amd64.tar
+ /usr/tools/scripts/pkg_fingerprint.sh /usr/tools/config/21.7/repo.pub
+ [ -n '' ]
+ rm -f /usr/local/opnsense/build/21.7/amd64/sets/packages-21.7.6_133-OpenSSL-amd64.tar.sig
+ cd /usr/local/opnsense/build/21.7/amd64/sets
+ ls -lah packages-21.7.6_133-OpenSSL-amd64.tar
-rw-r--r--  1 root  wheel   730M Dec 12 12:55 packages-21.7.6_133-OpenSSL-amd64.tar
+ [ -f /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-warn ]
+ echo '>>> WARNING: The build may have integrity issues!'
>>> WARNING: The build may have integrity issues!
+ cat /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-warn
>>> Rebuilt version 2.1.0 for dns/py-dnspython2@py38
>>> Rebuilt version 2.2.19 for net/haproxy22
+ [ -f /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-err ]
+ echo '>>> ERROR: The build encountered fatal issues!'
>>> ERROR: The build encountered fatal issues!
+ cat /usr/obj/usr/tools/config/21.7/OpenSSL:amd64/.pkg-err
>>> Aborted version 1.8.2 for security/vault
+ exit 1
*** Error code 1

Stop.
make: stopped in /usr/tools

update 2:

I think I may have found the issue:
Code: [Select]
[20211212074219] => Attempting to fetch https://codeload.github.com/kubernetes/client-go/tar.gz/v0.18.2?dummy=/kubernetes-client-go-v0.18.2_GH0.tar.gz
fetch: https://codeload.github.com/kubernetes/client-go/tar.gz/v0.18.2?dummy=/kubernetes-client-go-v0.18.2_GH0.tar.gz: size unknown
fetch: https://codeload.github.com/kubernetes/client-go/tar.gz/v0.18.2?dummy=/kubernetes-client-go-v0.18.2_GH0.tar.gz: size of remote file is not known
kubernetes-client-go-v0.18.2_GH0.tar.gz                710 kB  735 kBps    01s
[20211212074220] => Fetched file size mismatch (expected 727100, actual 727101)
[20211212074220] => Trying next site
[20211212074220] => Attempting to fetch http://distcache.FreeBSD.org/ports-distfiles/kubernetes-client-go-v0.18.2_GH0.tar.gz
fetch: http://distcache.FreeBSD.org/ports-distfiles/kubernetes-client-go-v0.18.2_GH0.tar.gz: Not Found
[20211212074222] => Couldn't fetch it - please try to retrieve this
[20211212074222] => port manually into /usr/ports/distfiles/ and try again.
*** Error code 1

Any idea how to overcome this. The link http://distcache.FreeBSD.org/ports-distfiles/kubernetes-client-go-v0.18.2_GH0.tar.gz is returning HTTP/403 error and the other link the file fails check due to 1Byte.
Title: Re: 21.7 build fails due to integrity issues of ports
Post by: franco on December 12, 2021, 09:52:13 am
> Couldn't fetch it - please try to retrieve this

As suggested on GitHub try to run the distfiles target before building to make sure all distfiles are properly fetched. Sometimes these files are temporarily not available or their checksum changes (the latter requiring an in-tree fix).

If the issue persists in FreeBSD ports itself raising a bug here is likely beneficial... https://bugs.freebsd.org/bugzilla/


Cheers,
Franco
Title: Re: 21.7 build fails due to integrity issues of ports
Post by: franco on December 12, 2021, 09:53:13 am
PS: The vault build log only has the trailing log lines but not the actual build/port error.