haproxy安装配置
# mv haproxy-1.3.15.5 /usr/local/haproxy# cd /usr/local/haproxy/# make TARGET=linux26[root@test haproxy]# pwd/usr/local/haproxy# groupadd haproxy# useradd haproxy -g haproxy通过/etc/passwd查看haproxy得uid和
# wget http://haproxy.1wt.eu/download/1.3/src/haproxy-1.3.15.5.tar.gz
# tar zxvf haproxy-1.3.15.5.tar.gz
# more README 部分如下:
To build haproxy, you have to choose your target OS amongst the following ones
and assign it to the TARGET variable :
- linux22 for Linux 2.2
- linux24 for Linux 2.4 and above (default)
- linux24e for Linux 2.4 with support for a working epoll (> 0.21)
- linux24eold for Linux 2.4 with support for a broken epoll (<= 0.21)
- linux26 for Linux 2.6 and above
# mv haproxy-1.3.15.5 /usr/local/haproxy
# cd /usr/local/haproxy/
# make TARGET=linux26
[root@test haproxy]# pwd
/usr/local/haproxy
# groupadd haproxy
# useradd haproxy -g haproxy
通过/etc/passwd查看haproxy得uid和gid分别为504/506
# chmod u+x /var/log/haproxy.log
[root@test haproxy]# vi myself.conf
关于配置详细参考:
http://haproxy.1wt.eu/download/1.3/doc/haproxy-en.txt
[root@test haproxy]# ./haproxy -f /usr/local/haproxy/myself.conf
[root@test haproxy]# lsof -i:90
COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME
haproxy 18019 haproxy 4u IPv4 307402 TCP *:dnsix (LISTEN)
haproxy 18020 haproxy 4u IPv4 307402 TCP *:dnsix (LISTEN)
http://192.168.1.250:90/stats
用户名admin密码admin
更多推荐
所有评论(0)