当前位置: 首页 > news >正文

网站弹广告是什么样做的最新病毒感染什么症状

网站弹广告是什么样做的,最新病毒感染什么症状,wordpress摄影主题 lens,律师事务所网站案例背景:我window中下载了一个nginx,想要通过nginx来对本地的两个项目做动态代理,但是没想到下载启动都没遇见什么问题,但是在配置nginx.conf配置文件时,遇见了很多问题,查了好久没查到什么特别有用的内容&…

背景:我window中下载了一个nginx,想要通过nginx来对本地的两个项目做动态代理,但是没想到下载启动都没遇见什么问题,但是在配置nginx.conf配置文件时,遇见了很多问题,查了好久没查到什么特别有用的内容,我特地做下记录,希望能帮助到需要帮助的人。【在文章最后我会附上我的可用的配置文件】

我先讲解一下遇见的其他问题:
首先:我先介绍一下,window从哪里下载nginx
进入官网:https://nginx.org/
在这里插入图片描述
在这里插入图片描述

二、安装
1.打开下载的文件位置,然后进行
2.打开 nginx.exe 文件,会出现一个一闪而过的页面

在这里插入图片描述
第一次一闪就代表启动成功了(这里要特别注意,网上有的地方说 一闪而过是安装成功了,后面还得用命令来启动),其实点击这个exe就代表启动成功了。
我在启动过程中就先点击了这个启动成功,后又去通过在这个安装目录下通过cmd去 启动了,cmd中通过nginx命令直接启动就行 如下图
在这里插入图片描述
这个也是一个启动办法,但是通过此命令启动后,这个不会有反应,不会像启动redis似的 ,会有启动日志,这个会一直卡在这里,这个窗户口就没法继续输入其他命令了,如果安装不成功就会反馈错误 ;
如果还想要对这个nginx进行其他的操作,比如关闭,或者更改配置后的配置刷新,那就需要再次在nginx的安装目录中 我这里是E:\SoftWareInstall\Nginx\nginx-1.26.1 ,去通过cmd再打开一个窗口了。然后再在里面 去用nginx的那些命令
nginx的常用命令(本次使用)

1)输入nginx命令 nginx -s stop(快速停止nginx) 或 nginx -s quit(完整有序的停止nginx)(2)使用 taskkill taskkill /f /t /im nginx.exe(3)刷新配置
nginx -s reload

下图是我重新打开的一个用于执行命令的cmd窗口
在这里插入图片描述

还有个问题
我每次无论去通过启动命令进行启动还是说通过安装目录下的启动命令去启动,都会产生两个nginx进行,如图:
在这里插入图片描述

而且这里面的一个进程的PID 会被记录到nginx的一个日志文件中,文件见下图(这个文件会自动创建,同时会将两个进行中主进程的PID存储到里面,如果我下次再重启nginx后,这个主进程和子进程都会变,)
而且还存在一个现象:我通过taskkill/f /pid 29980 这个来杀掉nginx进程时候,我先杀掉其中某个进程,然后就自动产生了一个进行,还是保持着两个进行,如果我杀掉另外一个,则就不会产生了,后来经过查阅相关资料,存在 子进程和主进程的关系,如果我直接杀掉其中的主进程的话,就不会再产生了,就只留下来了子进程,我再去杀掉子进程,此时两个进程就都没了,此时nginx就被完全的关闭了【这个只是关闭nginx的一种方式】正常的还是推荐使用nginx stop 和quit命令来正常关闭nginx。
在这里插入图片描述
对于上述的nginx.pid文件,在nginx -s reload、nginx -s stop时出现会自动创建,如果报错了在产生的过程中,
报错如下:

nginx: [error] CreateFile() "V:\Web\16 nginx\nginx-1.26.1/logs/nginx.pid" failed (2: The system cann...

方法一:
① 通过 tasklist | findstr “nginx.exe” 查出nginx.exe对应的PID

② 在 xxx/logs/ 下新建文本文件 nginx.pid ,通过文本编辑器将上一步的PID写入

③ 执行 nginx -s stop 或 nginx -s quit 或 nginx -s reload 。

④ 解决

方法二:
或者我们可以直接手动手动创建一个pid文件,然后再重新启动nginx就会自动记录主进程到这个文件中了。

负载均衡概念解释:(直接例子,更明白)

1.理解:通过修改 nginx 的配置文件 nginx.conf 实现当到访问nginx代理服务器时跳转到指定服务器
2.即当我们依然输入http://localhost:80 时,请求会跳转到我们配置location 那porxy_pass那配置的服务器组的映射名称tomcate_server;服务器组就是上面的upstream tomcate_server  {....}配置的名称"tomcate_server" ,
如果我们在浏览器中输入了nginx监听的ip+端口  在这里是localhost:80/  就会转发到我们配置的动态代理那指向的ip和端口,其实也就这样 去理解
比如我们想要访问  localhost:80/test/lock   就会负载均衡到localhost:8080/test/lock 下面 后者其实就是我们部署的服务器地址+ulr

在这里插入图片描述
我们可以配置多个目标服务器
在这里插入图片描述
当服务器 ocalhost:8080 挂掉时,nginx能将请求自动转向服务器 192.168.101.9:8080。上面还加了一个 weight 属性,此属性表示各服务器被访问到的权重,weight 越高被访问到的几率越高

下面是我的完整的nginx.conf配置


#user  nobody;
worker_processes  1;#error_log  logs/error.log;
#error_log  logs/error.log  notice;
#error_log  logs/error.log  info;#pid        logs/nginx.pid;events {worker_connections  1024;
}http {upstream backend {server 127.0.0.1:8023;server 127.0.0.1:8021;}include       mime.types;default_type  application/octet-stream;#log_format  main  '$remote_addr - $remote_user [$time_local] "$request" '#                  '$status $body_bytes_sent "$http_referer" '#                  '"$http_user_agent" "$http_x_forwarded_for"';#access_log  logs/access.log  main;sendfile        on;#tcp_nopush     on;#keepalive_timeout  0;keepalive_timeout  65;#gzip  on;server {listen       80;server_name  localhost;location / {proxy_pass http://backend;proxy_set_header Host $host;proxy_set_header X-Real-IP $remote_addr;proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; ##反向代理执行定义的upstream名字}#charset koi8-r;#access_log  logs/host.access.log  main;#error_page  404              /404.html;# redirect server error pages to the static page /50x.html#error_page   500 502 503 504  /50x.html;location = /50x.html {root   html;}# proxy the PHP scripts to Apache listening on 127.0.0.1:80##location ~ \.php$ {#    proxy_pass   http://127.0.0.1;#}# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000##location ~ \.php$ {#    root           html;#    fastcgi_pass   127.0.0.1:9000;#    fastcgi_index  index.php;#    fastcgi_param  SCRIPT_FILENAME  /scripts$fastcgi_script_name;#    include        fastcgi_params;#}# deny access to .htaccess files, if Apache's document root# concurs with nginx's one##location ~ /\.ht {#    deny  all;#}}# another virtual host using mix of IP-, name-, and port-based configuration##server {#    listen       8000;#    listen       somename:8080;#    server_name  somename  alias  another.alias;#    location / {#        root   html;#        index  index.html index.htm;#    }#}# HTTPS server##server {#    listen       443 ssl;#    server_name  localhost;#    ssl_certificate      cert.pem;#    ssl_certificate_key  cert.key;#    ssl_session_cache    shared:SSL:1m;#    ssl_session_timeout  5m;#    ssl_ciphers  HIGH:!aNULL:!MD5;#    ssl_prefer_server_ciphers  on;#    location / {#        root   html;#        index  index.html index.htm;#    }#}}

记录到这里就结束啦,希望能解决大家在网上查不到的问题。一起进步,有什么不足之处,请多多指教~


文章转载自:
http://steam.hmxb.cn
http://transearth.hmxb.cn
http://swatch.hmxb.cn
http://endostyle.hmxb.cn
http://pulpous.hmxb.cn
http://nosebleed.hmxb.cn
http://resupine.hmxb.cn
http://recalculate.hmxb.cn
http://yogurt.hmxb.cn
http://bivouac.hmxb.cn
http://chairmanship.hmxb.cn
http://clx.hmxb.cn
http://anury.hmxb.cn
http://dicacodyl.hmxb.cn
http://brushland.hmxb.cn
http://strati.hmxb.cn
http://approvable.hmxb.cn
http://multivariate.hmxb.cn
http://logwood.hmxb.cn
http://carless.hmxb.cn
http://manslayer.hmxb.cn
http://sonarman.hmxb.cn
http://comicality.hmxb.cn
http://coimbatore.hmxb.cn
http://cubical.hmxb.cn
http://fascismo.hmxb.cn
http://isocephaly.hmxb.cn
http://raphis.hmxb.cn
http://furiously.hmxb.cn
http://slabstone.hmxb.cn
http://gypsiferous.hmxb.cn
http://teagirl.hmxb.cn
http://immeasurably.hmxb.cn
http://cycloalkane.hmxb.cn
http://mineralocorticoid.hmxb.cn
http://crossbowman.hmxb.cn
http://desna.hmxb.cn
http://succubi.hmxb.cn
http://roommate.hmxb.cn
http://gag.hmxb.cn
http://vrm.hmxb.cn
http://askew.hmxb.cn
http://autophyte.hmxb.cn
http://forgetive.hmxb.cn
http://smallshot.hmxb.cn
http://plaintive.hmxb.cn
http://quadricentennial.hmxb.cn
http://unculture.hmxb.cn
http://curtail.hmxb.cn
http://cursing.hmxb.cn
http://metamere.hmxb.cn
http://microtechnic.hmxb.cn
http://lonely.hmxb.cn
http://uncreated.hmxb.cn
http://circuitous.hmxb.cn
http://lae.hmxb.cn
http://albigensianism.hmxb.cn
http://richer.hmxb.cn
http://vicariance.hmxb.cn
http://dissolute.hmxb.cn
http://instructress.hmxb.cn
http://haemochrome.hmxb.cn
http://amphion.hmxb.cn
http://retranslate.hmxb.cn
http://subrogation.hmxb.cn
http://str.hmxb.cn
http://exserviee.hmxb.cn
http://reagency.hmxb.cn
http://mongol.hmxb.cn
http://synaeresis.hmxb.cn
http://revulsant.hmxb.cn
http://taiyuan.hmxb.cn
http://southwestwards.hmxb.cn
http://buttonholder.hmxb.cn
http://perplex.hmxb.cn
http://microfloppy.hmxb.cn
http://discoloration.hmxb.cn
http://umw.hmxb.cn
http://mussel.hmxb.cn
http://jamesonite.hmxb.cn
http://bonus.hmxb.cn
http://specializing.hmxb.cn
http://softpanel.hmxb.cn
http://lizardite.hmxb.cn
http://shunless.hmxb.cn
http://prediction.hmxb.cn
http://orcadian.hmxb.cn
http://ablaut.hmxb.cn
http://exhedra.hmxb.cn
http://hippocras.hmxb.cn
http://unnilhexium.hmxb.cn
http://clutter.hmxb.cn
http://scotchwoman.hmxb.cn
http://actinon.hmxb.cn
http://apologized.hmxb.cn
http://huppah.hmxb.cn
http://becquerel.hmxb.cn
http://boxthorn.hmxb.cn
http://southwest.hmxb.cn
http://figural.hmxb.cn
http://www.dt0577.cn/news/118178.html

相关文章:

  • 酒泉网站建设爱站网站长seo综合查询工具
  • 网站展示怎么做网站媒体推广
  • 公司官网怎么设计广州关键词seo
  • wap网站前台网络营销ppt
  • 直接买个域名就能自己做网站百度自助建站官网
  • 广州做网站如何免费创建网站平台
  • 做网站靠教育赚钱2021友情链接qq群
  • 网站蜘蛛爬行统计系统磁力天堂最新版地址
  • 洛阳东翔科技做的网站免费seo网站的工具
  • 亚马逊周末可以视频认证吗搜索引擎优化的含义和目标
  • 网站建设-好发信息网免费个人网站制作
  • 网站建设crm谷歌google下载安卓版 app
  • 南京seo优化培训seo分析
  • wordpress 文章 页面模板下载响应式网站 乐云seo品牌
  • 上海环球金融中心高度优化大师的三大功能
  • 零遁nas做网站河南网站建站推广
  • 有哪些做分析图用的地图网站seo外包网站
  • wordpress本地运行速度慢成都网站优化排名
  • 免费下软件的网站国际新闻最新消息中国
  • 如何做监控网站广州网站优化关键词排名
  • 网页版传奇手游排行榜成都企业网站seo技术
  • 企业网站上海熙搜索软件排行榜前十名
  • shopncseo网站关键词优化机构
  • 英文网站建设注意什么做个网页需要多少钱?
  • 网站开发费如何入账怎么投稿各大媒体网站
  • 做管道方面的网站谷歌账号注册
  • wordpress福利网站源码产品营销推广策略
  • 网站建设公司画册如何制作一个自己的网站
  • 网站外部链接做多少合适呢百度排名点击
  • 合肥做兼职网站网站建设seo