error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

General support questions
Post Reply
system79
Posts: 3
Joined: 2020/05/07 18:32:25

error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

Post by system79 » 2020/05/07 18:43:30

Hi all)

Connecting dynamic module ngx_http_headers_more_filter_module


#nginx -V

Code: Select all

nginx version: nginx/1.10.3
built by gcc 4.4.7 20120313 (Red Hat 4.4.7-23) (GCC)
built with OpenSSL 1.0.1e-fips 11 Feb 2013
TLS SNI support enabled
configure arguments: --prefix=/usr/share/nginx --sbin-path=/usr/sbin/nginx --modules-path=/usr/lib64/nginx/modules --conf-path=/etc/nginx/nginx.conf --error-log-path=/var/log/nginx/error.log --http-log-path=/var/log/nginx/access.log --http-client-body-temp-path=/var/lib/nginx/tmp/client_body --http-proxy-temp-path=/var/lib/nginx/tmp/proxy --http-fastcgi-temp-path=/var/lib/nginx/tmp/fastcgi --http-uwsgi-temp-path=/var/lib/nginx/tmp/uwsgi --http-scgi-temp-path=/var/lib/nginx/tmp/scgi --pid-path=/var/run/nginx.pid --lock-path=/var/lock/subsys/nginx --user=nginx --group=nginx --with-file-aio --with-ipv6 --with-http_ssl_module --with-http_v2_module --with-http_realip_module --with-http_addition_module --with-http_xslt_module=dynamic --with-http_image_filter_module=dynamic --with-http_geoip_module=dynamic --with-http_sub_module --with-http_dav_module --with-http_flv_module --with-http_mp4_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_random_index_module --with-http_secure_link_module --with-http_degradation_module --with-http_slice_module --with-http_stub_status_module --with-http_perl_module=dynamic --with-mail=dynamic --with-mail_ssl_module --with-pcre --with-pcre-jit --with-stream=dynamic --with-stream_ssl_module --with-debug --with-cc-opt='-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic' --with-ld-opt=' -Wl,-E'
#wget 'nginx.org/download/nginx-1.10.3.tar.gz'

#git clone https://github.com/openresty/headers-more-nginx-module

conf module

Code: Select all

ngx_addon_name=ngx_http_headers_more_filter_module

HEADERS_MORE_SRCS="                                                         \
                $ngx_addon_dir/src/ngx_http_headers_more_filter_module.c    \
                $ngx_addon_dir/src/ngx_http_headers_more_headers_out.c      \
                $ngx_addon_dir/src/ngx_http_headers_more_headers_in.c       \
                $ngx_addon_dir/src/ngx_http_headers_more_util.c             \
                "

HEADERS_MORE_DEPS="                                                         \
                $ngx_addon_dir/src/ddebug.h                                 \
                $ngx_addon_dir/src/ngx_http_headers_more_filter_module.h    \
                $ngx_addon_dir/src/ngx_http_headers_more_headers_in.h       \
                $ngx_addon_dir/src/ngx_http_headers_more_headers_out.h      \
                $ngx_addon_dir/src/ngx_http_headers_more_headers_in.h       \
                $ngx_addon_dir/src/ngx_http_headers_more_util.h             \
                "

if test -n "$ngx_module_link"; then
    ngx_module_type=HTTP_AUX_FILTER
    ngx_module_name=$ngx_addon_name
    ngx_module_incs=
    ngx_module_deps="$HEADERS_MORE_DEPS"
    ngx_module_srcs="$HEADERS_MORE_SRCS"
    ngx_module_libs=

    . auto/module
else
    HTTP_AUX_FILTER_MODULES="$HTTP_AUX_FILTER_MODULES $ngx_addon_name"
    NGX_ADDON_SRCS="$NGX_ADDON_SRCS $HEADERS_MORE_SRCS"
    NGX_ADDON_DEPS="$NGX_ADDON_DEPS $HEADERS_MORE_DEPS"
fi
compile

Code: Select all

cd /tmp/nginx-1.10.3/
./configure --prefix=/tmp/nginx-1.10.3 \
     --add-dynamic-module=/tmp/headers-more-nginx-module
ok

Code: Select all

Configuration summary
  + using system PCRE library
  + OpenSSL library is not used
  + using builtin md5 code
  + sha1 library is not found
  + using system zlib library

  nginx path prefix: "/tmp/nginx-1.10.3"
  nginx binary file: "/tmp/nginx-1.10.3/sbin/nginx"
  nginx modules path: "/tmp/nginx-1.10.3/modules"
  nginx configuration prefix: "/tmp/nginx-1.10.3/conf"
  nginx configuration file: "/tmp/nginx-1.10.3/conf/nginx.conf"
  nginx pid file: "/tmp/nginx-1.10.3/logs/nginx.pid"
  nginx error log file: "/tmp/nginx-1.10.3/logs/error.log"
  nginx http access log file: "/tmp/nginx-1.10.3/logs/access.log"
   nginx http client request body temporary files: "client_body_temp"
  nginx http proxy temporary files: "proxy_temp"
  nginx http fastcgi temporary files: "fastcgi_temp"
  nginx http uwsgi temporary files: "uwsgi_temp"
  nginx http scgi temporary files: "scgi_temp"
#make modules

Code: Select all

make -f objs/Makefile modules
make[1]: Entering directory `/tmp/nginx-1.10.3'
cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/h                                      ttp -I src/http/modules \
                -o objs/addon/src/ngx_http_headers_more_filter_module.o \
                /tmp/headers-more-nginx-module/src/ngx_http_headers_more_filter_module.c
cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/h                                      ttp -I src/http/modules \
                -o objs/addon/src/ngx_http_headers_more_headers_out.o \
                /tmp/headers-more-nginx-module/src/ngx_http_headers_more_headers_out.c
cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/h                                      ttp -I src/http/modules \
                -o objs/addon/src/ngx_http_headers_more_headers_in.o \
                /tmp/headers-more-nginx-module/src/ngx_http_headers_more_headers_in.c
cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/h                                      ttp -I src/http/modules \
                -o objs/addon/src/ngx_http_headers_more_util.o \
                /tmp/headers-more-nginx-module/src/ngx_http_headers_more_util.c
cc -c -fPIC -pipe  -O -W -Wall -Wpointer-arith -Wno-unused-parameter -Werror -g  -I src/core -I src/event -I src/event/modules -I src/os/unix -I objs -I src/h                                      ttp -I src/http/modules \
                -o objs/ngx_http_headers_more_filter_module_modules.o \
                objs/ngx_http_headers_more_filter_module_modules.c
cc -o objs/ngx_http_headers_more_filter_module.so \
        objs/addon/src/ngx_http_headers_more_filter_module.o \
        objs/addon/src/ngx_http_headers_more_headers_out.o \
        objs/addon/src/ngx_http_headers_more_headers_in.o \
        objs/addon/src/ngx_http_headers_more_util.o \
        objs/ngx_http_headers_more_filter_module_modules.o \
        -shared
make[1]: Leaving directory `/tmp/nginx-1.10.3'
nginx.conf

load_module /ngx_http_headers_more_filter_module.so;

check
nginx -t

Code: Select all

nginx: [emerg] module "/usr/lib64/nginx/modules/ngx_http_headers_more_filter_module.so" is not binary compatible in /etc/nginx/nginx.conf:12
nginx: configuration file /etc/nginx/nginx.conf test failed
Help me, please )

Whoever
Posts: 1124
Joined: 2013/09/06 03:12:10

Re: error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

Post by Whoever » 2020/05/09 05:10:14

Why are you trying to install this in a system that will be EOL in just over 6 months?

system79
Posts: 3
Joined: 2020/05/07 18:32:25

Re: error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

Post by system79 » 2020/05/09 12:21:20

system has worked for 7 years) It's too early to update ;)

User avatar
TrevorH
Forum Moderator
Posts: 29134
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

Post by TrevorH » 2020/05/09 12:59:07

"too early"? CentOS 6 is based on RHEL 6 which was released in 2010. It is already beyond its original intended EOL date as Red Hat extended the lifespan from 7 years to 10. You now have around 6 months left before it dies completely and the patches being released by Red Hat for it are becoming less frequent and patching only the most severe vulnerabilities.
CentOS 6 will die in November 2020 - migrate sooner rather than later!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

system79
Posts: 3
Joined: 2020/05/07 18:32:25

Re: error dynamic module nginx 1.10.3 ngx_http_headers_more_filter_module

Post by system79 » 2020/05/10 16:06:35

TrevorH, I know, but I happy with centos 6 :)
___________
Compile nginx from sources. + --add-module=/headers-more-nginx-module. Well, I've solved that problem.

Post Reply

Return to “CentOS 6 - General Support”