
nginx
PHP搬砖操作工
明天会更好
展开
-
php nginx 负载均衡
1:nginx服务器192.168.182.128:8081/ 代码服务器: 192.168.182.129:81 192.168.182.131:812:在nginx服务器配置nginx.confupstream tomcatserver1{ server 192.168.182.129:81 weight=3; server 192.168.182.131:81; }server{ ...原创 2021-11-23 17:22:38 · 1468 阅读 · 0 评论 -
nginx 基本配置
下面给大家上一个配置文件########### 每个指令必须有分号结束。##################user administrator administrators; #配置用户或者组,默认为nobody nobody。#worker_processes 2; #允许生成的进程数,默认为1#pid /nginx/pid/nginx.pid; #指定nginx进程运行文件存放地址error_log log/error.log debug; #制定日志路径,级别。这个设置可以放入.转载 2021-01-27 13:57:14 · 111 阅读 · 0 评论 -
nginx expires缓存提升网站负载
在访问量比较大的网站中,利用客户端来缓存网站上不经常变更的图片,是给服务器减压的一个很方便且实用的做法在nginx 中配置如下1)可以在http段中或者server段中或者location段中加入location ~ .(jpg|jpeg|gif|png){expires 1d;}2)重启下nginx3)强制刷新页面(注意:服务器的日期要准确,如果服务器的日期落后于实际日期,可能导致缓存失效)expires 30s; //表示把数据缓存30秒expires 30m;//表示把数据缓原创 2021-01-25 15:45:14 · 244 阅读 · 0 评论 -
nginx gzip压缩提升网站速度
代码:gzip on;gzip_buffers 32 4k;gzip_min_length 200;gzip_comp_level 6;gzip_types text/plain application/javascript application/x-javascripttext/css application/xml text/xml text/javascript;gzip_vary on;转自或参考:Nginx优化之gzip压缩提升网站速度https://blog.csdn.n转载 2021-01-25 11:59:46 · 210 阅读 · 0 评论 -
nginx http 变成https 服务器端配置
第一步:打开服务器443端口第二步:上传生成好的证书第三部:配置文件C:\phpStudy\PHPTutorial\nginx\confserver { listen 80; server_name bhmcow.hi-cloud.net; //更换域名 #charset koi8-r; #acces...原创 2019-07-09 09:29:15 · 235 阅读 · 0 评论 -
Nginx 安装 SSL 配置 HTTPS 超详细完整全过程
原地址 :https://www.hack520.com/481.html说到Nginx服务器,个人认为最大特点就是轻量级和高性能。通过在几台不同的服务器上进行测试,发现它的并发能力特别强,并且相对而言吃的内存少很多。目前已是绝大多数站长的首选 HTTP 和反向代理服务器。站长自己的网站,包括承接企业服务器运维服务所采用的都是 Nginx。Apache 当然也可以,如果有兴趣,可以看一下...转载 2019-06-19 13:13:09 · 9850 阅读 · 1 评论 -
windows下nginx配置报错GetFileAttributesEx
在配置Nginx的时候,发现配置没有问题,但是老是访问不了。2019/05/27 23:50:16 [crit] 2404#6852: *7 GetFileAttributesEx() "H:\phpStudy\PHPTutorial\WWW\larval est\project_name\public" failed (123: The filename, directory nam...原创 2019-05-28 00:05:24 · 676 阅读 · 0 评论