Welcome! Log In Create A New Profile

Advanced

Nginx as LB to redirect/return to upstream server instead of Proxy

October 15, 2018 03:08AM
We want to use Nginx as LB in a way so that Nginx can return 301 or 302 redirect to client instead of Proxying request to backend/upstream servers.

It is required as Server which is configured as LB is having limited throughput of 1 Gbps while upstream servers are having throughput of 10Gbps .

We want users to directly connect to Upstream Server for Data delivery.
Nginx LB Server to make sure that all upstream are up and functional before giving 301 or 302 redirect to any of upstream server

Example:

http://nginxlb.com/data/download

Nginx LB Returns Redirected URL to Client 301 or 302 ( That upstream should be up)

http://upstreamserver1.com/data/download
http://upstreamserver2.com/data/download

Is this possible by :

return 301 http://$upstream_addr/data/download
Subject Author Posted

Nginx as LB to redirect/return to upstream server instead of Proxy

anish10dec October 15, 2018 03:08AM

Re: Nginx as LB to redirect/return to upstream server instead of Proxy

Aleksandar Lazic October 15, 2018 09:16AM

Re: Nginx as LB to redirect/return to upstream server instead of Proxy

Maxim Dounin October 15, 2018 10:46AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 222
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready