current location:Home > Technical Articles > Operation and Maintenance > Nginx
- Direction:
- All web3.0 Backend Development Web Front-end Database Operation and Maintenance Development Tools PHP Framework Daily Programming WeChat Applet Common Problem Other Tech CMS Tutorial Java System Tutorial Computer Tutorials Hardware Tutorial Mobile Tutorial Software Tutorial Mobile Game Tutorial
- Classify:
-
- How to solve the problem 'Welcome to nginx on Fedora!' after installing nginx in Centos7
- Problem description: When installing nginxsudoyuminstallnginx on Tencent Cloud centos7, open the default webpage and display welcometonginxonfedora! And there is no default.conf file in the /etc/nginx/conf.d directory. Reason: Tencent Cloud’s epel source is downloaded by default, which is fedora. Solution • Preparation sudoyuminstallyum- utils • Create nginx.repo file sudovim /etc/yum.repos.d/nginx.repo and add the following content [nginx-stable] name=nginxstab
- Nginx 1302 2023-05-20 18:22:27
-
- How to solve the problem that the port is occupied when opening Nginx
- As shown in the figure: Check the port occupancy: sudonetstat-apn|grep80 Check the process occupying the port: ps-ef|grep3345 From the results, we can see that port 80 is occupied by nginx itself. You can kill the process and restart nginxsudokill-93345sudonetstat-apn |After grep80 successfully kills the process, start nginx. Start nginx successfully. Enter the IP address of the system where nginx is located in the browser to verify whether nginx starts successfully. The following introduces the startup, stop and restart of nginx. The startup code format: nginx installation directory address - cnginx configuration file address for example: [
- Nginx 5481 2023-05-20 17:46:06
-
- How to use Nginx to handle Vue's development environment
- 1. The local test domain name needs to be the same as the online domain name in order to correctly deliver cookies and perform SSO testing. Note: Since the relevant cookies are added to the fourth-level domain name after sso login, the local test domain name and the online interface domain name need to be the same. 2. The plan is to configure the host file so that the online domain name points to localhost: 127.0.0.1product.xxx.xxx.com and configure nginx for corresponding forwarding: server{listen80;listen[::]:80;server_name${product.xxx.xxx. com};location/api{proxy_passhtt
- Nginx 1198 2023-05-20 17:16:06
-
- How to configure a reverse proxy using Nginx
- General configuration Under normal circumstances, friends who are familiar with nginx know that if you need to configure a reverse proxy, just write a location context and proxy module. If you need to customize the prefix, use a rewrite module. A simple example is as follows: location~/dfs/group([0-9]){proxy_passhttp://localhost:8080;rewrite^/dfs/(.*)$/$1break;proxy_set_headerhost$host:$server_port;proxy_set_headerx-real -ip$re
- Nginx 2097 2023-05-20 16:28:06
-
- How to speed up nginx performance
- Turn on gzip configuration #Turn on gzipgzipon;#The minimum file to enable gzip compression, files smaller than the set value will not be compressed gzip_min_length1k;#gzip compression level, 1-10, the larger the number, the better the compression, and the more CPU time will be taken up, later There will be detailed descriptions of gzip_comp_level2;# file types for compression. JavaScript comes in many forms. The values can be found in the mime.types file. gzip_typestext/plainapplication/javascriptapplication/x-javascripttext/c
- Nginx 982 2023-05-20 15:25:14
-
- How to deploy and run CentOS7 Docker Nginx
- 1. Resource preparation dockerfile file#"ported"byadammillerfrom#https://github.com/fedora-cloud/fedora-dockerfiles##originallywrittenforfedora-dockerfilesby#scollierfromcentos:centos7maintainerthecentosprojectrunyum-yupdate;yumcleanallrunyum-yinstallepel-relea
- Nginx 813 2023-05-20 15:19:06
-
- How to solve nginx 502 Bad Gateway error
- Trigger conditions for nginx502 The most common occurrence of 502 errors is when the backend host crashes. There is such a configuration in the upstream configuration: proxy_next_upstream. This configuration specifies what kind of errors nginx encounters when fetching data from a back-end host. It will go to the next back-end host. What is written in it is all the 502s that will appear. In this case, the default is errortimeout. Error refers to crashes, disconnections, etc. Timeout refers to read blocking timeout, which is easier to understand. I usually write it all: proxy_next_upstreamerrortimeoutinvalid_headerhtt
- Nginx 4600 2023-05-20 15:16:06
-
- How to configure port forwarding of non-80 ports in Nginx server
- nginx can be easily configured as a reverse proxy server: server{ listen80; server_namelocalhost; location/{ proxy_passhttp://x.x.x.x:9500; proxy_set_headerhost$host:80; proxy_set_headerx-real-ip$remote_addr; proxy_set_headerx-forwarded-for$proxy_add_x_forwarded_ for ; proxy_se
- Nginx 1790 2023-05-20 15:04:18
-
- How to deploy nginx, php and virtual host configuration in CentOS environment
- Deployment time: 2012-07-24os environment: centos6.1nginx: nginx-1.2.2php:php5.3.140, install the dependency package and copy the code as follows: yuminstallopenssl-develpcre-develzlib-devellibjpeg-devellibpng-develfreetype-develgccmake1, add www user To execute nginx, copy the code as follows: useradd-m-r-s/sbin/nologin-d/opt/web/www2. Create a temporary directory. Copy the code as follows: mk
- Nginx 1214 2023-05-20 14:25:06
-
- How to configure Tcp load balancing in Nginx
- This article uses Nginx as a proxy server for load balancing. It is just a simple application example and does not involve principles. (The hosts here are limited. Port 8000 of the 42.192.22.128 host is used as the proxy server listening port, and 8181 is the service listening port.) The client accesses the proxy server, and the proxy server distributes the request to the corresponding server. Modify the Nginx configuration file to configure Tcp load balancing (the configuration file is in /usr/local/nginx/conf/nginx.config after Nginx installation, and the Nginx executable program is in the /usr/local/nginx/sbin directory) in nginx. conf configuration file
- Nginx 2641 2023-05-20 13:16:20
-
- How to configure Nginx reverse proxy under Linux
- In addition to preventing vicious attacks from the external network on the intranet server, caching to reduce server pressure and access security control, using a reverse proxy can also perform load balancing and distribute user requests to multiple services. 1. Upgrade the system, uninstall Apache to release port 80 Yumupdate-yYumremovehttpd-y2, and install EPELreporpm-Uvhhttp://mirror.ancl.hawaii.edu/linux/epel/6/i386/epel-release-6-8.noarch.rpmEPELrepo Download address: https://fedoraproject.org
- Nginx 1116 2023-05-20 13:07:06
-
- How to bind nginx reverse proxy secondary domain name
- 1. Application scenarios We often encounter situations where multiple web sites are established on the same server. A common approach is to configure different ports for different sites so that they can be accessed in the form of ip:port. But after all, using IP to access is inconvenient, not vivid, and not easy to remember. Then, we can bind different domain names to each site. (Here we only talk about the public network situation) Even if we only have one domain name, we can set up multiple second-level domain names, which is easy to achieve using nginx. 2. Basic requirements Usually, online tutorials will directly post a piece of code for the configuration file and tell us that this is OK. But I found that many novices cannot succeed like bloggers after looking at the tutorial configuration, so next I
- Nginx 2122 2023-05-20 10:55:24
-
- How to install and tune Nginx
- Optimization before Nginx compilation [root@linuxprobe~]#wgethttp://nginx.org/download/nginx-1.10.1.tar.gz[root@linuxprobe~]#tarxvfnginx-1.10.1.tar.gz-C/ usr/local/src/[root@linuxprobe~]#cd/usr/local/src/nginx-1.10.1/ Pre-compilation optimization is mainly used to modify the program name, etc., for example: [root@linuxprobenginx-1.10. 1]#curl-Ihtt
- Nginx 1306 2023-05-20 09:55:20
-
- Analysis of nginScript examples of nginx
- Let me first briefly talk about nginxnginx [enginex], which is the most popular and best web server and reverse proxy server in the world. According to statistics from third-party companies, at least 23% of servers around the world currently use nginx, and of course this number is still expanding. It is also the first choice for domestic BAT, so this is why we paid attention to it for the first time. nginx can mainly do the following: 1. Working on the seventh layer of tcp, it can analyze and process all contents of the http protocol. 2. Support lua, perl, javascript dynamic language 3. Support third-party plug-ins Let’s talk about nginscript1. nginscript is java
- Nginx 585 2023-05-20 09:52:05
-
- How nginx+iis implements simple load balancing
- 1. nginx installation nginx is a lightweight web server/reverse proxy server and email (imap/pop3) proxy server, and is released under a bsd-like protocol. It was developed by Russian programmer igorsysoev and is used by Russia's large portal website and search engine Rambler (Russian: рамблер). Its characteristics are that it occupies less memory and has strong concurrency capabilities. In fact, nginx’s concurrency capabilities do perform better among web servers of the same type. Users of nginx websites in mainland China include: Baidu, Sina, NetEase, Tencent, etc. The latest version of nginx is 1.9.3. The one I downloaded is the window version.
- Nginx 899 2023-05-20 09:43:05