Date: Sat, 21 Aug 2021 10:41:41 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-arm@FreeBSD.org Subject: [Bug 257981] Segmentation fault on pkg install Message-ID: <bug-257981-7@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D257981 Bug ID: 257981 Summary: Segmentation fault on pkg install Product: Base System Version: CURRENT Hardware: arm64 OS: Any Status: New Severity: Affects Only Me Priority: --- Component: arm Assignee: freebsd-arm@FreeBSD.org Reporter: dan.kotowski@a9development.com For about a week or so I've been experiencing regular segfaults when using poudriere: ``` =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D<phase= : pkg-depends >=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D> dialog4ports-0.1.6 depends on file: /usr/local/sbin/pkg - not = found =3D=3D=3D> Installing existing package /packages/All/pkg-1.17.1.pkg [14arm64-usrports-job-02] Installing pkg-1.17.1... [14arm64-usrports-job-02] Extracting pkg-1.17.1: .........Child process pid=3D27588 terminated abnormally: Segmentation fault *** Error code 139 Stop. make: stopped in /usr/ports/ports-mgmt/dialog4ports =3D>> Cleaning up wrkdir =3D=3D=3D> Cleaning for dialog4ports-0.1.6 build of ports-mgmt/dialog4ports | dialog4ports-0.1.6 ended at Mon Aug 16 10:14:11 UTC 2021 build time: 00:00:04 !!! build failure encountered !!! ``` Diving into the jail I can reproduce by hand as well: ``` root@14arm64-usrports:/tmp # /tmp/usr/local/sbin/pkg-static -d install pkg DBG(1)[17023]> pkg initialized Updating local repository catalogue... DBG(1)[17023]> PkgRepo: verifying update for local DBG(1)[17023]> PkgRepo: need forced update of local DBG(1)[17023]> Pkgrepo, begin update of '/var/db/pkg/repo-local.sqlite' DBG(1)[17023]> Request to fetch file:///packages/meta.conf DBG(1)[17023]> Fetch: fetcher chosen: file [14arm64-usrports] Fetching meta.conf: 100% 163 B 0.2kB/s 00:01 DBG(1)[17023]> Request to fetch file:///packages/packagesite.pkg DBG(1)[17023]> Fetch: fetcher chosen: file [14arm64-usrports] Fetching packagesite.pkg: 100% 1 KiB 1.1kB/s 00:= 01 DBG(1)[17023]> PkgRepo: extracting packagesite.yaml of repo local DBG(1)[17326]> PkgRepo: extracting signature of repo in a sandbox Sandboxed process pid=3D17326 terminated abnormally by signal: 11 pkg-static: Repo extraction failed Unable to update repository local Error updating repositories! ``` Notice that it terminated abnomrally while extracting the signature. Then t= he stack trace: ``` [New LWP 100493] Core was generated by `pkg-static add /tmp//pkg.pkg.buINJX'. Program terminated with signal SIGSEGV, Segmentation fault. #0 0x0000000000000000 in ?? () (gdb) bt #0 0x0000000000000000 in ?? () #1 0x00000000006007cc in SHA256_Pad (ctx=3D0x40cb6928) at /usr/src/sys/crypto/sha2/sha256c.c:257 #2 _libmd_SHA256_Final (digest=3D0x40cb68e8 '\245' <repeats 64 times>, "g\346\tj\205\256g\273r\363n<:\365O\245\177R\016Q\214h\005\233\253=D9=83\03= 7\031\315\340[\200", ctx=3D0x40cb6928) at /usr/src/sys/crypto/sha2/sha256c.c:328 #3 0x00000000005f3584 in lzma_sha256_finish (check=3D0x40cb6928, check@entry=3D0x40cb68e8) at /usr/src/contrib/xz/src/liblzma/check/check.h:= 167 #4 0x00000000005f309c in lzma_index_hash_decode (index_hash=3D0x40cb68c0, in=3Din@entry=3D0x40d2d58d "(z/\376?\232f8\374\334\061V?\374f0@m\n\214\346E=E5=8D=86YE\327\343~4e\232\= 376-Z\377\a+k\003=C4=BCN0\035\022\006\253C\257 L\352`<_\377`=CA=9A~\362\a\236\273&\021\221\357\306\313=3D\202\271c\027\066= D\217\004\066\377\a\305h\271\260\376\"=3D\215\252n\023\235\f\022\004L\201\3= 52L\374\237\"z\327\320\037\322\325\325\322\350qa\b\327\017SjY\034j~\351\372= ]dI$\354\347\237Sz\224\376\355\204W\022\027\365\064\207\241\311\353\302&\27= 6zY\001\311F\352\222>x9\206{?)\246\312\024\202)\036#\227\310{\337\\\002\232= \201\354$(\242\261=C3=A3\276\b\374:\376\032&\351", <incomplete sequence \356>, in_pos=3Din_pos@entry=3D0xffffffff5150, in_size=3D<optimized out>, in_size@entry=3D12435) at /usr/src/contrib/xz/src/liblzma/common/index_hash.c:295 #5 0x00000000005f2010 in stream_decode (coder_ptr=3D0x40d0d200, allocator= =3D0x0, in=3D0x40d2d58d "(z/\376?\232f8\374\334\061V?\374f0@m\n\214\346E=E5=8D=86YE\327\343~4e\232\= 376-Z\377\a+k\003=C4=BCN0\035\022\006\253C\257 L\352`<_\377`=CA=9A~\362\a\236\273&\021\221\357\306\313=3D\202\271c\027\066= D\217\004\066\377\a\305h\271\260\376\"=3D\215\252n\023\235\f\022\004L\201\3= 52L\374\237\"z\327\320\037\322\325\325\322\350qa\b\327\017SjY\034j~\351\372= ]dI$\354\347\237Sz\224\376\355\204W\022\027\365\064\207\241\311\353\302&\27= 6zY\001\311F\352\222>x9\206{?)\246\312\024\202)\036#\227\310{\337\\\002\232= \201\354$(\242\261=C3=A3\276\b\374:\376\032&\351", <incomplete sequence \356>, in_pos=3D0xffffffff5150, in_size=3D12435, out=3D0x40d398c0 "rotect", out_pos=3D0xffffffff5148, out_size=3D65536, action=3DLZMA_RUN) at /usr/src/contrib/xz/src/liblzma/common/stream_decoder= .c:282 #6 0x00000000005edaa4 in lzma_code (strm=3D<optimized out>, strm@entry=3D0x40cdc5c0, action=3D<optimized out>) at /usr/src/contrib/xz/src/liblzma/common/common.c:287 #7 0x00000000005a45fc in xz_filter_read (self=3D0x40cdc500, p=3D0x40cdc590= ) at /usr/src/contrib/libarchive/libarchive/archive_read_support_filter_xz.c:692 #8 0x0000000000595184 in __archive_read_filter_ahead (filter=3D0x40cdc500, min=3D1, avail=3D0xffffffff5280) at /usr/src/contrib/libarchive/libarchive/archive_read.c:1385 #9 0x00000000005a5c10 in archive_read_format_tar_read_data (a=3D0x40c7c800, buff=3D0xffffffff52e0, size=3D0xffffffff52d8, offset=3D0xffffffff52d0) at /usr/src/contrib/libarchive/libarchive/archive_read_support_format_tar.c:623 #10 0x000000000059660c in archive_read_data_into_fd (a=3D0x40c7c800, fd=3D1= 0) at /usr/src/contrib/libarchive/libarchive/archive_read_data_into_fd.c:101 #11 0x000000000051b23c in create_regfile () #12 0x000000000051bd60 in do_extract_regfile () #13 0x0000000000519780 in pkg_add_common () #14 0x000000000039e6f0 in exec_add () #15 0x00000000003a7dcc in main () ``` My best guess is that this was introduced somehow by one of 69d8dc20be6ca10cf87c98223121c4121aff42cc or c81ea895b563c4d1e39468a8525284b7474fe850, but I can't say for sure just yet. Hardware: SolidRun HoneyComb LX2 Workstation, based on NXP Layerscape LX216= 0A 16-core Arm Cortex A72 OS Version: CURRENT at 9781c28c6d63 --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-257981-7>