Saturday, March 15, 2014

Installer HAproxy on Debian Wheezy backports

I love Debian, but high disagree not put HAproxy in Wheezy.
Do you know how many people using it over the world, do you know how stable HAproxy is?

To install HAproxy on Debian Wheezy, have to through backports.

First add backports in /etc/apt/sources.list :

deb http://ftp.debian.org/debian/ wheezy-backports main


Then install haproxy:

apt-get update ; apt-get install haproxy


To start HAproxy:

service haproxy start


Auto start after reboot:

Edit Default /etc/default/haproxy

# Set ENABLED to 1 if you want the init script to start haproxy.
ENABLED=1


Edit Init job: /etc/init.d/haproxy

HAPROXY=/usr/sbin/haproxy
EXTRAOPTS=
ENABLED=1


I will post another one about how to install HAproxy by compile from source.

Reference:https://packages.debian.org/wheezy-backports/haproxy

5 comments:

  1. hi, thanks for the tip, i'll bookmark your blog.
    Cya.

    ReplyDelete
  2. It's wrong to edit /etc/init.d/haproxy
    After setting ENABLED=1 in /etc/default/haproxy, the init script should start the service!

    ReplyDelete
  3. Thanks for your comments.

    ReplyDelete
  4. Hey, thanks for the great tip, I was looking on how to implement a small load balancer under Haproxy and I wasn't able to install it inside debian 7

    ReplyDelete