bind-process [ all | odd | even | <number 1-64>[-<number 1-64>] ] ...

Limit visibility of an instance to a certain set of processes numbers.

May be used in sections :

defaults frontend listen backend yes yes yes yes yes yes yes yes

Arguments : all All process will see this instance. This is the default. It may be used to override a default value.

odd This instance will be enabled on processes 1,3,5,...63. This option may be combined with other numbers.

even This instance will be enabled on processes 2,4,6,...64. This option may be combined with other numbers. Do not use it with less than 2 processes otherwise some instances might be missing from all processes.

number The instance will be enabled on this process number or range, whose values must all be between 1 and 32 or 64 depending on the machine's word size. If a proxy is bound to process numbers greater than the configured global.nbproc, it will either be forced to process #1 if a single process was specified, or to all processes otherwise. This keyword limits binding of certain instances to certain processes. This is useful in order not to have too many processes listening to the same ports. For instance, on a dual-core machine, it might make sense to set 'nbproc 2' in the global section, then distributes the listeners among 'odd' and 'even' instances.

At the moment, it is not possible to reference more than 32 or 64 processes using this keyword, but this should be more than enough for most setups. Please note that 'all' really means all processes regardless of the machine's word size, and is not limited to the first 32 or 64.

Each "bind" line may further be limited to a subset of the proxy's processes, please consult the "process" bind keyword in section 5.1.

When a frontend has no explicit "bind-process" line, it tries to bind to all the processes referenced by its "bind" lines. That means that frontends can easily adapt to their listeners' processes.

If some backends are referenced by frontends bound to other processes, the backend automatically inherits the frontend's processes.

Example :

listen app_ip1
    bind 10.0.0.1:80
    bind-process odd

listen app_ip2
    bind 10.0.0.2:80
    bind-process even

listen management
    bind 10.0.0.3:80
    bind-process 1 2 3 4

listen management
    bind 10.0.0.4:80
    bind-process 1-4

See also : "nbproc" in global section, and "process" in section 5.1.

results matching ""

    No results matching ""