Installation HaProxy v2

Deazer

Head Developer
Staff member
To start entering information about what a proxy is and what the HaProxy v2 protocol is used for:
In our case, the proxy is used in two situations. The first is to optimize the traffic route if your server is designed for different continents. The second is defense against attacks and its balancing.
And so why we added support for HAProxy v2 - the answer is quite simple, if you use a proxy without this protocol, all players will display the IP of the proxy server that optimizes the traffic route or protects against DDoS attacks, when this protocol is enabled, the players will display their real IP.
You can purchase the following proxies:
1. Variti - https://www.variti.com/ or by contact on our forum @Variti https://lucera2.com/threads/vega-zaschita-igrovyx-serverov.1718/
2. Ddos-Guard - https://ddos-guard.net/
3. StormWall - https://stormwall.pro/ (in their cases, just say that you need a ha proxy v2 to filter TCP traffic)
4. L2Up - https://host.l2up.ru
and many more who provide services of this nature. This is not a recommendation of where to buy, I just gave examples of such companies.

1) And so we go to the detailed server settings and start with the server login:
authserver.properties
In the LoginserverPort = -1 line, we need to specify -1
In the line HAProxyLoginserverHostname = we need to specify the IP of your server to which to accept connections from HAProxy. Not the address of the proxy itself.
HAProxyLoginserverPort = 2121 is the port for receiving connections from HAProxy. For example, a proxy service provider redirects connections from TCP port (for the L2 authorization server it will be 2106) to your port 2121.
server.properties
The line HAProxyGameserverPort = 7778 specifies the port for receiving connections from HAProxy. For example, a proxying service provider redirects connections from TCP port (for an L2 game server it will be 7777) to your port 7778 and leave the line empty GameserverPort =

Important * in such an implementation of the settings, it is advisable to close all incoming and outgoing traffic except for the IP proxy, also do not forget to inform the new IP address of the license binding so that the license server can get to it.

2) Now consider the option with a proxy slider for route optimization and go to authserver\config\proxyservers.xml

And as an example, we configure it for our proxy:
For example:
XML:
<list>
    <!--
    Usage: <proxyServer origId="<original_server_id>" proxyId="<proxy_server_id>" proxyHost="<proxy_host>" proxyPort="<proxy_port>" />
    Where:
        <original_server_id>    - Original server id
        <proxy_server_id>       - Server ID used as a proxy server
        <proxy_host>            - Host address (IP) of the proxy server
        <proxy_port>            - Proxy servers port
    Example:
   -->
        <proxyServer origId="1" proxyId="2" proxyHost="185.165.123.192" proxyPort="7777" />
        <proxyServer origId="1" proxyId="3" proxyHost="185.165.123.193" proxyPort="7777" />
        <proxyServer origId="1" proxyId="4" proxyHost="185.165.123.194" proxyPort="7777" />
</list>

At the same time, the service provider must allow connections and traffic from their addresses.
185.165.123.192, 185.165.123.193 and 185.165.123.194 and ports 7777 to your game server on the port specified in HAProxyGameserverPort = 7777, leave this line empty GameserverPort =
 
Last edited:
Back
Top