I'm trying to get simple content switching configured in HAProxy
1.3.15.7 under OpenBSD 4.6 macppc. The original, full description can
be found here:

   
<http://serverfault.com/questions/104350/why-am-i-getting-errors-in-my-haproxy-content-switching-config>

However, I've slimmed /etc/haproxy/haproxy.cfg down to the following:

   global
           log 127.0.0.1   local0
           log 127.0.0.1   local1 notice
           #log loghost    local0 info
           maxconn 1024
           chroot /var/haproxy
           uid 604
           gid 604
           daemon
           #debug
           #quiet
           pidfile /var/run/haproxy.pid

   defaults
           log     global
           mode    http
           option  httplog
           option  dontlognull
           option  redispatch
           retries 3
           maxconn 2000
           contimeout      5000
           clitimeout      50000
           srvtimeout      50000
           stats enable
           stats auth user:pass

   frontend http_proxy *:80
           default_backend server1

   backend server1
           server httpd_server1 192.168.1.3:80

However, when I attempt to start HAProxy, I get the following errors:

   [ALERT] 019/090010 (10214) : parsing /etc/haproxy/haproxy.cfg :
backend 'bento' has no dispatch address and is not in transparent or
balance mode.
   [ALERT] 019/090010 (10214) : Errors found in configuration file, aborting.
   [ALERT] 019/090010 (10214) : Error reading configuration file :
/etc/haproxy/haproxy.cfg

At the suggestion of a user in the #haproxy on irc.freenode.net, I
tried moving the frontend's address & port to a separate bind line
('bind :80', 'bind *:80', and 'bind 0.0.0.0:80' all produced the same
error). Also tried a 'source' in the backend ('source 192.168.1.7') to
no avail.

A little more background: I installed libpcre & haproxy using the
existing OpenBSD 4.6 macppc port, but I have to problem building both
from scratch if you'd suggest it. Also, the same interface with a
private IP is used both for the incoming requests to HAProxy on port
80 and the outgoing redirects to the backend servers (server, in this
stripped down config).

I'd greatly appreciate any thoughts and suggestions.

Thanks,

Morgan Aldridge
---
morg...@makkintosshu.com
http://www.makkintosshu.com/

Reply via email to