NavigationContentFooter
Jump toSuggest an edit

How to create frontends and backends

Reviewed on 18 June 2024Published on 26 May 2021

When you create a Load Balancer, you can either add frontends and backends during the initial creation process, or you can create your Load Balancer without any frontends or backends and add them later. This page explains how to create and configure frontends and backends for your Load Balancer at any stage.

Before you start

To complete the actions presented below, you must have:

  • A Scaleway account logged into the console
  • Owner status or IAM permissions allowing you to perform actions in the intended Organization

How to create a frontend during creation of your Load Balancer

  1. Follow the steps for creating a Load Balancer. At the last stage, click Add frontend and backend. The following screen displays, the first step inviting you to configure a frontend:

  2. Enter a name for your frontend.

  3. Enter a port number. The frontend will listen on this port, and forward the requests it receives from clients to the backend(s). Note that you cannot add an SSL certificate at this stage, but you can add one after the creation of the Load Balancer. Similarly, you will be able to enable HTTP/3 after adding a certificate.

    Tip

    For more help with configuring your frontend, see our dedicated reference documentation.

Continue to the next section for configuring a backend. You will finalize creation of your frontend and backend at the same time, at the end of this section.

How to create a backend during creation of your Load Balancer

Follow the steps for creating a Load Balancer and creating a frontend. After configuring your frontend, the next section of the screen displays as shown below, inviting you to configure a backend.

Configuring basic settings

  1. Enter a name for your backend.

  2. Enter a protocol and port for your backend. The Load Balancer initiates connections to its backend servers using the protocol and port you define here. Available protocols are HTTP or TCP.

    Tip

    For HTTPS, choose HTTP and activate TLS encryption.

  3. Choose whether to activate TLS encryption (default setting is deactivated), to encrypt connections between the Load Balancer and its backend servers.

  4. Choose whether to activate proxy protocol (default setting is deactivated), to transfer connection information from the client through the Load Balancer and on to the destination backend server. If you choose to activate proxy protocol, you are prompted to select the version to use.

    Tip

    For more help understanding and choosing basic configuration settings for your backend, see our dedicated reference documentation.

Continue to the next section for configuring traffic management.

Configuring traffic management

Traffic management configuration lets you define how your Load Balancer's backend forwards traffic to its final destination backend servers.

  1. Select a balancing method. This determines how the backend distributes requests between its backend servers. The following methods are available:

    • Round-robin (default): Requests are sent to each backend server in turn.
    • Least connections: Requests are forwarded to the backend server with the fewest current connections.
    • First available: Requests are forwarded to the first backend server with available connection slots.
  2. Add the Server IP addresses of the servers the Load Balancer will forward requests/connections to. These will be your backend servers.

    Note

    If you want your Load Balancer to communicate with its backend servers over an attached Private Network, ensure that you enter the servers' private IP addresses on that network. This is necessary in the case of a private Load Balancer, but may also be desired for public Load Balancers attached to Private Networks where backend servers are on the same Private Network.

  3. Choose whether to activate sticky sessions (default setting is deactivated). Sticky sessions enable the Load Balancer to bind a given user's sessions to a specific backend server. If you choose to activate sticky sessions, you are prompted to select either IP-based (clients' IPs are used to bind sessions) or cookie-based (an HTTP cookie is used to bind sessions, and you must choose a name for the cookie).

    Tip

    For more help choosing traffic management settings for your backend, see our dedicated reference documentation.

Continue to the next section for configuring advanced settings.

Configuring advanced settings

Advanced settings are already configured for you at recommended default values. However, if you wish to modify these values you can do so by clicking the Advanced settings button, to access parameters for timeout values, backend protection, connection retries and a customized error page.

Tip

For more help choosing advanced settings for your backend, see our dedicated reference documentation.

Continue to the next section for configuring health checks.

Configuring health checks

Health checks are regular, automized attempts by the Load Balancer to communicate with backend servers. This ensures that servers are listening and healthy.

  1. Select a health check type. Various protocols are available, including HTTP, TCP, MYSQL, and more. Depending on the health check type you choose, you may be prompted to enter additional information.

  2. Choose whether to use proxy protocol during health checks. Proxy protocol enables the original client IP address to be passed to the backend server in a standardized way during health checks. The proxy protocol setting for health checks is inherited from the backend configuration but you can choose to override it. For more information, click the link in the green tip box below.

  3. Choose whether to edit more settings for health checks by clicking the Advanced settings button. Otherwise, these settings will be left at the recommended default values.

    Tip

    For more help setting up health checks for your backend, including advanced settings such as defining intervals between health checks, timeout values and the unhealthy threshold, see our dedicated reference documentation.

Confirming creation of your frontend and backend

When you have finished configuring your frontend and backend, click Create frontend and backend at the bottom of the page. The frontend and backend are created and attached to the Load Balancer.

How to create a frontend after creation of your Load Balancer

You can add one or many frontends to your Load Balancer after its creation. Follow the steps below.

  1. Click Load Balancers in the Network section of the Scaleway console side menu. The Load Balancer dashboard displays.

  2. Click the Load Balancer you want to add frontends to. The Load Balancer information page displays.

  3. Click the Frontends tab.

  4. Click the + Add frontend button. The frontend creation wizard displays.

  5. Enter a name, port and (if necessary) SSL certificate(s) for your new frontend. Note that each frontend must listen on a different port.

  6. Choose a backend to attach the frontend to, from the drop-down list provided. Alternatively, you can click the link to create a new backend, which opens the backend creation wizard in a new screen.

  7. Under Advanced Settings, optionally use the «Toogle Icon» to enable HTTP/3. The availability of this setting depends on your Load Balancer’s configuration.

    Tip

    For more help with configuring your frontend, see our dedicated reference documentation.

  8. Click Create frontend.

How to create a backend after creation of your Load Balancer

You can add one or many backends to your Load Balancer after its creation. Follow the steps below.

  1. Click Load Balancers in the Network section of the Scaleway console side menu. The Load Balancer dashboard displays.

  2. Click the Load Balancer you want to add backends to. The Load Balancer information page displays.

  3. Click the Backends tab.

  4. Click the + Add backend button. The backend creation wizard displays.

  5. Follow the steps above for configuring basic settings, configuring traffic management, configuring advanced settings and configuring health checks

  6. Click Create backend at the bottom of the page to finish.

See also
How to create a Load BalancerHow to manage frontends and backends
Was this page helpful?
API DocsScaleway consoleDedibox consoleScaleway LearningScaleway.comPricingBlogCareers
© 2023-2024 – Scaleway