Name
README-windows - README for the official 32-bit and 64-bit Windows
builds of OpenResty
Table of Contents
* Name
* Description
* Debugging
* Caveats
* TODO
* "Details About The Building Process"
* Author
* "Copyright & License"
Description
The official binary Win32 and Win64 distributions of OpenResty can be
downloaded from the following web page:
https://openresty.org/en/download.html
To start the NGINX server of the nginx server of the Win32 binary
distribution of OpenResty:
start nginx
You can also specify the "-p PATH/" option to override the default
server prefix, as in
cd /path/to/my/openresty/app/
start nginx -p $PWD
Then you can use the "tasklist" command to check the nginx processes
running in the background:
C:\> tasklist /fi "imagename eq nginx.exe"
Image Name PID Session Name Session# Mem Usage
========================= ======== ================ =========== ============
nginx.exe 4616 Console 1 7,412 K
nginx.exe 5836 Console 1 7,800 K
One of the two processes is the master process while the other is the
worker.
If you are using the MSYS2 bash instead of the "cmd.exe" console, then
you should replace the "/fi" option with "-fi" in the command above
instead.
You can quickly shut down the server like this:
nginx -s stop
or gracefully shut it down like this:
nginx -s quit
You can also forcibly kill the nginx processes via their PIDs with
"taskkill", as in
C:\> taskkill /pid 5488 /F
where the PID (5488 in this example) can be found via the aforementioned
"tasklist" command.
Again, you should use the form "-pid" and "-F" for the options if you
are in an MSYS2 bash session.
Similarly, you can use the "nginx -s reload" command to reload nginx
configurations without stopping the server. And you can use "nginx -s
reopen" to instruct nginx to re-open all the log files.
You can run the "resty" script like this:
C:\> resty -e "ngx.say('Hello, OpenResty!')"
Hello, OpenResty!
The "resty" command-line utility requires a Perl interpreter installed
in your system and visible to your PATH environment. Any perl
distributions should work, including StrawberryPerl, ActivePerl, and
MSYS2 perl. recommended though).
Debugging
Debug symbosl are enabled even in release builds. So that when things go
very wrong, one can still debug things with tools like MSYS2 GDB.
Inclusion of debug symbols make the binary files (".exe" and ".dll"
files) much larger, but it generally will not load into memory during
normal execution on a modern operating system.
Caveats
The Win32/Win64 port of the NGINX core supports the good old "select" IO
multiplexing mechanism only. The I/O Completion Ports (IOCP) feature is
*not* supported (yet). So do not use this build for production
environments with very high concurrency levels.
This Win32/Win64 build of OpenResty is mainly for developers who want to
develop their applications in native Windows environment (though they
eventually push the finished work onto a Linux or *BSD box, most of the
time).
TODO
* Add support for more than one NGINX worker processes.
* Add support for concurrent connections more than 1024.
* Switch to the Microsoft Visual Studio compiler toolchain for better
performance and easier binary package redistribution.
* Bundle StrawberryPerl to make command-line utilities like "resty"
work out of the box (without manually installing a Perl).
* Deliver an alternative Win32/Win64 binary package built with best
debuggin capabilities (like enabling NGINX debugging logs, disabling
C compiler optimizations, and enabling all the assertions and
checks).
Details About The Building Process
Usually you do not need to worry about how the Win32/Win64 binaries were
built on the maintainers'' side. But if you do, please read on.
The Win32/Win64 build of OpenResty is currently built via the
MSYS2/MinGW toolchain, including MinGW gcc 7.2.3, MSYS2 perl 5.24.4,
MSYS2 bash, MSYS2 make, and etc. Basically, it is currently built via
the following cmmands:
PCRE=pcre-8.42
ZLIB=zlib-1.2.11
OPENSSL=openssl-1.1.0h
mkdir -p objs/lib || exit 1
cd objs/lib || exit 1
ls ../../..
tar -xf ../../../$OPENSSL.tar.gz || exit 1
tar -xf ../../../$ZLIB.tar.gz || exit 1
tar -xf ../../../$PCRE.tar.gz || exit 1
cd ../..
cd objs/lib/$OPENSSL || exit 1
patch -p1 < ../../../patches/openssl-1.1.0d-sess_set_get_cb_yield.patch || exit 1
cd ../../..
./configure \
--with-cc=gcc \
--with-ipv6 \
--prefix= \
--with-cc-opt='-DFD_SETSIZE=1024' \
--sbin-path=nginx.exe \
--with-pcre-jit \
--without-http_rds_json_module \
--without-http_rds_csv_module \
--without-lua_rds_parser \
--with-ipv6 \
--with-stream \
--with-stream_ssl_module \
--with-stream_ssl_preread_module \
--with-http_v2_module \
--without-mail_pop3_module \
--without-mail_imap_module \
--without-mail_smtp_module \
--with-http_stub_status_module \
--with-http_realip_module \
--with-http_addition_module \
--with-http_auth_request_module \
--with-http_secure_link_module \
--with-http_random_index_module \
--with-http_gzip_static_module \
--with-http_sub_module \
--with-http_dav_module \
--with-http_flv_module \
--with-http_mp4_module \
--with-http_gunzip_module \
--with-select_module \
--with-luajit-xcflags="-DLUAJIT_NUMMODE=2 -DLUAJIT_ENABLE_LUA52COMPAT" \
--with-pcre=objs/lib/$PCRE \
--with-zlib=objs/lib/$ZLIB \
--with-openssl=objs/lib/$OPENSSL \
-j9 || exit 1
make -j9
make install
where the dependency library source tarballs for OpenSSL, Zlib, and PCRE
are downloaded from their official sites, respectively.
We automate these commands in a dedicated shell script named
build-win32.sh
<https://github.com/openresty/openresty/blob/master/util/build-win32.sh>
.
Furthermore, we automate the packaging process of the resulting binaries
and supporting files with this package-win32.sh
<https://github.com/openresty/openresty/blob/master/util/package-win32.s
h> script.
Usually you can just download and use the binary distribution of
OpenResty without installing the build toolchain.
Author
Yichun "agentzh" Zhang <agentzh@gmail.com>, OpenResty Inc.
Copyright & License
This module is licensed under the BSD license.
Copyright (C) 2015-2019, by Yichun "agentzh" Zhang (章亦春)
<agentzh@gmail.com>, OpenResty Inc.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
openresty-1.15.8.3-win64 (304个子文件)
resty.bat 35KB
restydoc.bat 16KB
restydoc-index.bat 9KB
nginx.conf 3KB
fastcgi.conf 1KB
COPYRIGHT 22KB
mime.types.default 5KB
nginx.conf.default 3KB
fastcgi.conf.default 1KB
fastcgi_params.default 1KB
uwsgi_params.default 681B
scgi_params.default 653B
lua51.dll 3.79MB
nginx.exe 23.05MB
luajit.exe 381KB
fastcgi_params 1KB
lua.h 12KB
lauxlib.h 6KB
luaconf.h 5KB
luajit.h 3KB
lualib.h 1KB
lua.hpp 135B
index.html 674B
50x.html 562B
koi-utf 3KB
koi-win 2KB
regex.lua 33KB
dis_x86.lua 33KB
dis_arm64.lua 30KB
resolver.lua 23KB
mysql.lua 21KB
dis_ppc.lua 20KB
dump.lua 20KB
dis_arm.lua 19KB
bcsave.lua 18KB
healthcheck.lua 18KB
pureffi.lua 17KB
pipe.lua 17KB
shdict.lua 16KB
memcached.lua 14KB
dis_mips.lua 13KB
ssl.lua 11KB
redis.lua 9KB
p.lua 9KB
request.lua 9KB
protocol.lua 8KB
vmdef.lua 8KB
client.lua 8KB
re.lua 7KB
bc.lua 6KB
aes.lua 6KB
v.lua 6KB
lrucache.lua 6KB
balancer.lua 5KB
upload.lua 5KB
base.lua 5KB
semaphore.lua 5KB
misc.lua 5KB
server.lua 5KB
lock.lua 5KB
errlog.lua 4KB
response.lua 4KB
time.lua 4KB
ocsp.lua 4KB
req.lua 4KB
var.lua 3KB
session.lua 2KB
base64.lua 2KB
conn.lua 2KB
count.lua 2KB
ndk.lua 2KB
ctx.lua 2KB
hash.lua 2KB
base64.lua 2KB
traffic.lua 1KB
uri.lua 1KB
process.lua 1KB
tablepool.lua 1KB
sha512.lua 1KB
sha256.lua 1KB
phase.lua 1KB
md5.lua 1KB
sha1.lua 1KB
exit.lua 1KB
sha224.lua 1KB
sha384.lua 1KB
zone.lua 1002B
utils.lua 874B
worker.lua 723B
dis_mips64el.lua 717B
dis_mipsel.lua 715B
dis_x64.lua 712B
dis_mips64.lua 706B
string.lua 698B
core.lua 642B
dis_arm64be.lua 619B
random.lua 616B
resp.lua 365B
sha.lua 236B
ngx_lua-0.10.15.pod 326KB
共 304 条
- 1
- 2
- 3
- 4
资源评论
tonyliult
- 粉丝: 12
- 资源: 3
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 基于HTML的旅游网页制作源码设计.zip
- 基于HTML的旅游网页制作源码设计.zip
- 大数据实战Demo系统-MaxCompute数据仓库数据转换实践(PDF格式).rar
- 六一儿童节代码祝福六一儿童节代码祝福六一儿童节代码祝福.txt
- sql语句sql语句sql语句sql语句.txt
- ubuntu20.04安装教程ubuntu20.04安装教程.txt
- imgcache.0
- 高分项目基于faster-rcnn知识蒸馏的目标检测模型增量深度学习方法源码.zip
- 基于python和图数据库neo4j构建电影应用(高分毕设项目)
- 基于yolov5+SAHI模块完成超分辨率以及小目标检测演示源码+运行说明.zip
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功