Opened 7 days ago

Last modified 7 days ago

#1831 new defect

ngx_http_perl_module + Perl 5.30.0

Reported by: kanai3id@… Owned by:
Priority: minor Milestone:
Component: nginx-module Version: 1.16.x
Keywords: Cc:
uname -a: Linux kanai-test 3.10.0-957.21.3.el7.x86_64 #1 SMP Tue Jun 18 16:35:19 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
nginx -V: nginx version: nginx/1.16.1 built with OpenSSL 1.1.1c 28 May 2019 TLS SNI support enabled configure arguments: --prefix=/app/local --with-threads --with-http_ssl_module --with-http_v2_module --with-openssl=/app/build/src/openssl/openssl-1.1.1c --with-http_realip_module --with-http_addition_module --with-http_xslt_module --with-http_image_filter_module --with-http_sub_module --with-http_dav_module --with-http_flv_module --with-http_gzip_static_module --with-http_random_index_module --with-http_secure_link_module --error-log-path=/data/logs/nginx/error.log --http-log-path=/data/logs/nginx/access.log --with-http_perl_module --with-perl=/usr/bin/perl --with-perl_modules_path=/app/local/cpan-lib --with-http_stub_status_module

Description

Hi

Report a bug in ngx_http_perl_module.
http://nginx.org/en/docs/http/ngx_http_perl_module.html

When reloaded(systemctl reload nginx), it becomes segfault. In this environment. Perl 5.28.2 does not have this problem.

regards,

--- Environment
OS: 7.6
Nginx: 1.16.1
Perl : 5.30.0

--- nginx.service
[Unit]
Description=Nginx
After=network.target
After=syslog.target

[Service]
Type=forking
User=root
Group=root
PIDFile=/var/run/nginx.pid
EnvironmentFile?=/etc/sysconfig/nginx
ExecStartPre?=/usr/local/sbin/nginx -t -c /usr/conf/nginx/nginx.conf
ExecStart?=/usr/local/sbin/nginx -c /usr/conf/nginx/nginx.conf
ExecReload?=/usr/bin/kill -HUP $MAINPID
Restart=on-failure
RestartPreventExitStatus?=1

[Install]
WantedBy?=multi-user.target

--- /var/log/messages
Aug 14 17:17:29 kanai-test kernel: nginx[29533]: segfault at 1b ip 00007f6ce82b375c sp 00007ffd836fc130 error 4 in libperl.so[7f6ce81fd000+336000]
Aug 14 17:17:29 kanai-test systemd: nginx.service: main process exited, code=killed, status=11/SEGV
Aug 14 17:17:29 kanai-test systemd: Reload failed for Nginx.
Aug 14 17:17:29 kanai-test systemd: Unit nginx.service entered failed state.
Aug 14 17:17:29 kanai-test systemd: nginx.service failed.

Change History (3)

comment:1 Changed 7 days ago by pluknet

Please provide stack trace and full configuration.

comment:2 Changed 7 days ago by mdounin

Just a note: we've seen previous reports about similar problems with Perl 5.30, without any perl-related configuration in nginx, see this thread. From the information available it looks like a bug in Perl.

comment:3 Changed 7 days ago by kanai3id@…

Thank you for important information.
Perl 5.28.2 has no problem, so use this version.

The following are additional comments on the confirmed phenomenon.
With nginx reload, the following message may be output to nginx error.log
--- error.log
2019/08/14 16:34:15 [alert] 23659#23659: perl_parse() failed: 1

Note: See TracTickets for help on using tickets.