Perlbal is our Perl-based reverse proxy load balancer and web server
来源:互联网 发布:家用投影仪 知乎 编辑:程序博客网 时间:2024/05/04 09:05
Perlbal
Perlbal is our Perl-based reverse proxy load balancer and web server.
Overview
Perlbal is a single-threaded event-based server supporting HTTP load balancing, web serving, and a mix of the two (see below).
One of the defining things about Perlbal is that almost everything can be configured or reconfigured on the fly without needing to restart the software. A basic configuration file containing a management port enables you to easily perform operations on a running instance of Perlbal.
Here is a basic list of the personalities and features that Perlbal implements at this time.
Role: Web Server
- Listen on a port, share from a directory
- Directory indexing
- Byte range support (clients can resume downloads)
- Can have directory index requests fall back to index file list
- I.e., requests for /foo/ go to /foo/index.html instead
- Multiple index files supported, tries one at a time until it finds one
- Persistent client connections (configurable)
- Almost all1 disk operations are done asynchronously as to not stall the event loop
- Configurable support for storing files (PUT, DELETE support)
1 Almost. When you enable PUT support, the close() operation is blocking. However, it’s generally pretty fast (we’ve had no problems). Also, directory indexing is a synchronous operation.
Role: Reverse Proxy
- Maintains pool of connected backend connections to reduce turnover
- Gets list of nodes either from asynchronously monitored node file, or from in-server pool objects which you can add/remove nodes from using the management interface.
- Intelligent load balancing based on what backend connections are free for a new request. No unreliable “weighting” numbers required.
- Can verify (using a quick OPTIONS request) that a backend connection is talking to a webserver and not just the kernel’s listen queue before sending client requests at it. Lower latency for the client.
- Has a high priority queue for sending requests through to backends quickly
- Uses cookies to determine if a request should go to fast queue (configurable)
- Highpri (high priority) plugin supports making requests high priority by URI or Host
- Can specify a relief level to let low priority requests through to prevent starvation
- Can allow X-Forwarded-For (and similar) headers from client based on client IP
- Configurable header management before sending request to backend
- Internal redirection to file or URL(s)
- Big one for us; a backend can instruct Perlbal to fetch the user’s data from a completely separate server and port and URL, 100% transparent to the user
- Can actually give Perlbal a list of URLs to try. Perlbal will find one that’s alive. Again, the end user sees no redirects happening.
- Can also redirect to a file, which Perlbal will serve non-blocking. See webserver mode above.
- Persistent client connections (configurable)
Statistics and Monitoring
- CPU usage (user, system)
- Total requests served across all services
- Requests service by individual backends
- Perlbal uptime
- All connected sockets (and tons of info about each)
- Outstanding connections to backends
- Backends that have recently failed verification
- Pending backend connections by service
- Total of all socket states by socket type
- Size (in seconds and number of connections) of all queues
- State of reproxy engine (queued requests, outstanding requests, backends)
- Loaded plugins per service
(All statistics are in machine readable form, easy to parse and write scripts that check on the status of Perlbal!)
Plugins (Extensibility)
Perlbal supports the concept of having per-service (and global) plugins that can override many parts of request handling and behavior. We have written custom plugins that send new headers to the backends, promote requests to the fast queue, maintain more detailed statistics, do image header manipulation, and more…
For more information on how plugins work, see the plugins directory in the distribution. They’re fairly self-explanatory.
Much more documentation needs to happen…
具体的安装方法可以见这里: http://wiki.ourlinux.net/pmwiki.php?n=Main.Perlbal
- Perlbal is our Perl-based reverse proxy load balancer and web server
- PeopleSoft and the Load Balancer
- Difference between proxy server and reverse proxy server
- Failed to start A high performance web server and a reverse proxy server 错误提示
- Proxy and Reverse Proxy
- Nginx and reverse proxy
- Reverse Proxy Web Sockets with Nginx and Socket.IO
- Building HA Load Balancer with HAProxy and keepalived
- Becoming an Xperf Xpert Part 7: Slow Profile Load and Our Very First Stack WalkHi my name is Randolp
- Web-based file and folder sharing with Apache-HTTP server
- apache load balancer 翻译
- OpenStack Load Balancer LBaaS
- Nginx Load Balancer Config
- PERL web server configration
- what's the different between forward proxy and reverse proxy?
- Reverse Proxy with Multiple Backend Web Servers
- What Is (and What Isn’t) in Our Array?
- Load Balancer in HBase 0.90
- welcome to fedora 7
- C#程序中Bug的快速修复方法
- DataGrid添加下拉列表框
- 常用函数和方法集汇总
- java新手入门必看的30个问题
- Perlbal is our Perl-based reverse proxy load balancer and web server
- movie,人,我
- biztalk中常用调试方法
- 去掉了灰色倒三角的漂亮下拉列表
- 提高页面访问速度 Posted on August 16th
- 不比做的事
- biztalk定制管道组件(pipeline component)的开发
- 十个信号显示:你单身的岁月已经过长
- Squid 配置手札 [1] Posted on August 16th