Nginx multi-Server reverse proxy configuration
The powerful regular expression support of Nginx can make the configuration of server_name flexible. If you want to create a multi-user blog, it is easy for each user to have their own second-level domain name.Let me talk about the use of server_name:Matching order of server_nameThe server_name command in nginx is mainly used to configure the name-based virtual
IP address, default is 0.0.0.0-N number, set Max connections, default is 4096-D do not go to background-K Use Ketama key allocation algorithm-f file, UNIX socket path to listen on. Default is Off-I number, max keep alive connections for one memcached server, default is 20-V VerbosePHP opens the extension php_memcache. DLL note version of the issuePhpinfo (); See if the extension is turned on$mem = new Memc
, you need to put. htaccess in the/home/ftp/pub Directory. the content is as follows:
-------
[Root @ shopu pub] # more. htaccess
AuthName Branch Office Public Software Download Area
AuthType Basic
AuthUserFile/etc/. usrpasswd
Require valid-user
------
Then use # htpasswd-c/etc/. usrpasswd user1
Create different external usernames and passwords that are allowed to access the file service in/pub.
II. reverse proxy configuration on the firewall:
Add t
] ~]# Cp/etc/squid/squid.conf/etc/squid/squid.conf.bak[Email protected] ~]# vim/etc/squid/squid.confFor the sake of convenience, I directly change the following line to http_access allow all, the reader can modify the allowable range.# and finally deny all other access to the This proxyHttp_access Deny AllRemember to add the following statement at the bottom of the configuration file, or squid will not start!Visible_hostname localhostIf you want to use transparent mode, add the keyword "Transpar
Ccproxy "Proxy Server"Ccproxy in June 2000, is the most popular domestic download volume of the largest domestic proxy server software. Mainly used for LAN shared broadband Internet access, ADSL shared Internet, dedicated line agent sharing, ISDN proxy sharing, satellite age
/var/cache/squid 100 16 256coredump_dir/usr/local/squid/var/cache/squiddns_nameservers 114.114.114.114 #dnsrefresh_pattern ^ftp:1440 20% 10080refresh_pattern ^gopher:1440 0% 1440refresh_pattern-i (/cgi-bin/|\?) 0 0% 0refre Sh_pattern. 0 20% 4320Finally, attach the configuration details:#acl all src 0.0.0.0/0.0.0.0 and http_access the Allow all option defines an access control list. For details see and squid Software # carry documentation. The access control list here allows all
Require Valid-user
------
Then use #htpasswd-c/etc/.usrpasswd user1
Create separate external user names and passwords that allow access to the file service under/pub.
Two. Reverse proxy configuration on the firewall:
Add the following line to/etc/httpd/conf/httpd.conf
Namevirtualhost 1.2.3.4
# 1.2.3.4 is a permanent IP address on the Internet of the firewall external NIC
ServerName www.yourdomain.com
Errorlog/var/log/httpd/error_log
Transferlog
First, a brief introduction to the classification of agents:
Agent score: Level 1~level 55 grades;
Or it can be divided into 3 categories: ·
A. All anonymous agents don't change your request.
Fields, making the server side look like there's a real client browser accessing it. Of course, your real IP is hidden. The server's webmaster does not think you are using a proxy.
B. Ordinary anonymous agents can
Article Title: detailed explanation of the use of the proxy server Squid. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
As the most popular operating system, Linux has become increasingly popular. Although Linux software is not rich yet, it is too early to replace WIND
Proxy server, there is no need to introduce, simply say the installation process. At the beginning of the hosting24 above, installation, how the installation has not been successful, replaced by Linode, half an hour on the deal, Guess hosting24 the agent made restrictions.
One, server description
A foreign VPS (recommended Linode), service-side squid
A company
prohibits access by Unbound Domain names or IP addresses.
Server {Listen 80 default;Server_name _;Return 500;Access_log off;}
The following is the configuration file conf. d/blog. conf of the reverse proxy of the website.
Server {Listen 80;Server_name blog.com; # website Domain NameLocation /{Proxy_pass http://ww
processEvents { Worker_connections 65535;}#设定http服务器, using its reverse proxy function to provide load balancing supportHTTP {#文件扩展名与文件类型映射表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 records which users, which pages, and the user's browser, IP, and
The previous article shared the Nginx + TOMCAT reverse Agent Load Balancing cluster Deployment Guide, the feeling is quite practical, but the general cluster deployment is based on a large number of visits, some enterprises may not use, similar to some of the corporate website, the visit is not very large, based on this new demand, today to share a special Nginx + Tomcat Reverse proxy How to deploy multiple sites on a single
number of connections allowed for a single processEvents { Worker_connections 65535;}#设定http服务器, using its reverse proxy function to provide load balancing supportHTTP {#文件扩展名与文件类型映射表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 records which users, wh
Nginx Write C module to block the HTTP proxy server access In this article using Apache to block the HTTP proxy server, we used Apache mod_rewrite to judge the visitor's HTTP head header, if you see signs of proxy, stop it, can further improve efficiency? So the idea of usin
Abstract
This paper gives a solution for how the server/client software can improve the performance significantly. We try to find way in the software itself, rather than the environment outside.
At last, I write an open source software, named game platform, to demonstrate this way is feasible and it can be expanded to all the server/client software's architecture.
Problem Statement
In
Recently done projects, the front end need to use the Nginx reverse proxy to forward the request, summed up the configuration on Windows and Mac, in case of query.First, WindowsModify the Nginx configuration file, nginx.conf.1) nginx.conf file, HTTP, the default open server is only one, listening to the 80 port:1 http{2XXXXX3server{4 listen; 5 XXXX6} 7 }2) We manually add a
Due to network environment restrictions, need to from the intranet (not directly connected to the outside network) to the external FTP upload, download files, only on the gateway server to set up the FTP reverse proxy (gateway server can connect the extranet and intranet, but not allow internal applications deployed on this machine).Several scenarios were tried:1
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.