Tuesday, March 02, 2021

net/nagios/check_mssql_health: sporadic build failures

This is the second time in recent weeks that the
net/nagios/check_mssql_health port failed to build during an amd64
bulk build, with the same weird reason: a supposed syntax error
in an awk regular expression. See below.

Re-running the same command in the work directory does not reproduce
the error.

I'm mystified.

------------------------------------------------------------------------
>>> Building on localhost under net/nagios/check_mssql_health
BDEPENDS = [databases/p5-DBD-Sybase;archivers/gtar]
DIST = [net/nagios/check_mssql_health:check_mssql_health-1.5.19.tar.gz]
FULLPKGNAME = check_mssql_health-1.5.19
RDEPENDS = [databases/p5-DBD-Sybase]
(Junk lock obtained for localhost at 1614639610.47)
>>> Running depends in net/nagios/check_mssql_health at 1614639610.54
last junk was in devel/spidermonkey78
/usr/sbin/pkg_add -aI -Drepair gtar-1.34 p5-DBD-Sybase-1.16p2
was: /usr/sbin/pkg_add -aI -Drepair gtar-1.34 p5-DBD-Sybase-1.16p2
/usr/sbin/pkg_add -aI -Drepair gtar-1.34 p5-DBD-Sybase-1.16p2
>>> Running show-prepare-results in net/nagios/check_mssql_health at 1614639612.32
===> net/nagios/check_mssql_health
===> check_mssql_health-1.5.19 depends on: p5-DBD-Sybase-* -> p5-DBD-Sybase-1.16p2
===> check_mssql_health-1.5.19 depends on: gtar-* -> gtar-1.34
gtar-1.34
p5-DBD-Sybase-1.16p2
(Junk lock released for localhost at 1614639612.63)
distfiles size=134966
>>> Running build in net/nagios/check_mssql_health at 1614639612.69
===> net/nagios/check_mssql_health
===> Checking files for check_mssql_health-1.5.19
`/usr/ports/distfiles/check_mssql_health-1.5.19.tar.gz' is up to date.
>> (SHA256) check_mssql_health-1.5.19.tar.gz: OK
===> Extracting for check_mssql_health-1.5.19
===> Patching for check_mssql_health-1.5.19
===> Compiler link: clang -> /usr/bin/clang
===> Compiler link: clang++ -> /usr/bin/clang++
===> Compiler link: cc -> /usr/bin/cc
===> Compiler link: c++ -> /usr/bin/c++
===> Generating configure for check_mssql_health-1.5.19
===> Configuring for check_mssql_health-1.5.19
Using /usr/obj/ports/check_mssql_health-1.5.19/config.site (generated)
configure: loading site script /usr/obj/ports/check_mssql_health-1.5.19/config.site
checking for a BSD-compatible install... /usr/obj/ports/check_mssql_health-1.5.19/bin/install -c
checking whether build environment is sane... yes
checking for gawk... (cached) awk
checking whether make sets $(MAKE)... (cached) yes
checking how to create a pax tar archive... gnutar
checking build system type... x86_64-unknown-openbsd6.9
checking host system type... x86_64-unknown-openbsd6.9
checking for a BSD-compatible install... /usr/obj/ports/check_mssql_health-1.5.19/bin/install -c
checking whether make sets $(MAKE)... (cached) yes
variable with_statefiles_dir is /var/tmp/check_mssql_health
variable with_mymodules_dir is /usr/local/libexec/nagios
variable with_mymodules_dyn_dir is /usr/local/libexec/nagios
checking for sh... /bin/sh
checking for perl... /usr/bin/perl
checking for gzip... /usr/bin/gzip
checking for gawk... (cached) /usr/bin/awk
checking for grep... (cached) /usr/bin/grep
checking for echo... /bin/echo
checking for sed... (cached) /usr/bin/sed
checking for cat... /bin/cat
configure: creating ./config.status
config.status: creating Makefile
config.status: creating plugins-scripts/Makefile
config.status: creating plugins-scripts/subst
config.status: creating t/Makefile
config.status: creating doc/Makefile
--with-perl: /usr/bin/perl
--with-statefiles-dir: /var/tmp/check_mssql_health
--with-nagios-user: _nagios
--with-nagios-group: _nagios
--with-mymodules-dir: /usr/local/libexec/nagios
--with-mymodules-dyn-dir: /usr/local/libexec/nagios
===> Building for check_mssql_health-1.5.19
Making all in plugins-scripts
/bin/echo "#! #PERL# -w" | /usr/bin/awk -f ./subst > check_mssql_health
/bin/echo >> check_mssql_health
/bin/echo "my %ERRORS=( OK => 0, WARNING => 1, CRITICAL => 2, UNKNOWN => 3 );" >> check_mssql_health
/bin/echo "my %ERRORCODES=( 0 => 'OK', 1 => 'WARNING', 2 => 'CRITICAL', 3 => 'UNKNOWN' );" >> check_mssql_health
for m in Nagios/DBD/MSSQL/Server/Memorypool.pm Nagios/DBD/MSSQL/Server/Database/Datafile.pm Nagios/DBD/MSSQL/Server/Database.pm Nagios/DBD/MSSQL/Server/Job.pm Nagios/DBD/MSSQL/Server.pm Nagios/Extraopts.pm; do /usr/bin/sed -e 's/^1;//g' < $m | /usr/bin/awk -f ./subst | /usr/bin/grep -v "my %ERROR" >> check_mssql_health; done
awk: syntax error in regular expression ^#! ?\/.*\/[a-z]{0,2}awk at
source line number 44 source file ./subst
context is
/^#! >>> ?\/.*\/[a-z]{0,2}awk/ <<< {sub(/^#! ?\/.*\/[a-z]{0,2}awk/,"#! /usr/bin/awk");}
*** Error 1 in plugins-scripts (Makefile:346 'check_mssql_health')
*** Error 1 in /usr/obj/ports/check_mssql_health-1.5.19/check_mssql_health-1.5.19 (Makefile:223 'all-recursive': @failcom='exit 1'; for f i...)
*** Error 2 in net/nagios/check_mssql_health (/usr/ports/infrastructure/mk/bsd.port.mk:2941 '/usr/obj/ports/check_mssql_health-1.5.19/.build_done')
*** Error 2 in net/nagios/check_mssql_health (/usr/ports/infrastructure/mk/bsd.port.mk:2596 'build': @lock=check_mssql_health-1.5.19; expor...)
===> Exiting net/nagios/check_mssql_health with an error
*** Error 1 in /usr/ports (infrastructure/mk/bsd.port.subdir.mk:137 'build': @: ${echo_msg:=echo}; : ${target:=build}; for i in ; do eval...)
>>> Ended at 1614639615.44
max_stuck=0.00/depends=1.79/show-prepare-results=0.37/build=2.81
Error: job failed with 512 on localhost at 1614639615

--
Christian "naddy" Weisgerber naddy@mips.inka.de

No comments:

Post a Comment