Load balancing Nexus is currently not supported by Sonatype, except by putting a Nexus instance in front of two withsmart-proxying enabled or via anewer feature.
Still, I gave it a shot, by sharing the filesystem with GlusterFS for the/storage, and trying toenable stickyness in the Apache Load Balancer config and in Nexus config for the UI.
With the UI I am failing miserably, as it seems the Nexus container does not honor the properties for setting the cookie value; using the following configuration at the moment:
For the storage it seems to work, by limiting toGET andHEAD requests only, still have to try opening toPOSTs. I was also unsure about the possible collateral effects of scheduled jobs, so all were disabled in the "secondary" node.
Has anybody achieved some level of trustworthy configuration for load-balancing nexus? The UI is not actually important to be load-balanced, I would be happy enough with the storage.
- 1Is the goal to achieve load balancing or high availability ?Tensibai– Tensibai2017-03-06 10:56:41 +00:00CommentedMar 6, 2017 at 10:56
- 1
- Old, but maybe stillrelevant blog postTensibai– Tensibai2017-03-06 15:38:00 +00:00CommentedMar 6, 2017 at 15:38
2 Answers2
Sonatype's Nexus 3 Prosupports High Availability through a couple of mechanisms that are collectively known as Component Fabric:
- Peer-to-peer Repository Managers means there is no one master, also known as a single point of failure. Packages are replicated between the nodes to ensure they are eventually consistent.
- Storage Backends mean you can use high durability storage such as S3.
- Dynamic Nodes enable auto-scaling support to increase capacity when demand is high and decrease it when demand is low to reduce costs.
It's not really in Sonatype's interests to support HA for the community project as it would cannibalize some of the enterprise customers from their paid product.
- Thanks, we are using Nexus pro licensed indeed, but we are stuck on v 2.x for the foreseeable future unfortunately.ᴳᵁᴵᴰᴼ– ᴳᵁᴵᴰᴼ2017-04-10 07:58:58 +00:00CommentedApr 10, 2017 at 7:58
- 1@ᴳᵁᴵᴰᴼ unfortunate indeed, any chance of setting up Nexus 3 as a mirror of Nexus 2?Richard Slater– Richard Slater2017-04-10 21:26:29 +00:00CommentedApr 10, 2017 at 21:26
- Is High Availability - Clustering (HA-C) in Nexus Repository Manager OSS as well ?Nitul– Nitul2017-12-15 12:05:01 +00:00CommentedDec 15, 2017 at 12:05
- Doesn'tdeploying Nexus on Kubernetes essentially enable high availability, or am I getting this wrong?lostsoul29– lostsoul292018-05-25 15:50:25 +00:00CommentedMay 25, 2018 at 15:50
- @lostsoul29 It depends on the storage you are using. If you use k8s in AWS your EBS volumes will end up in a Availability Zone X. If this all your nodes in that instance die, you won't be able to mount the volume. So no HA here…Pascal Hofmann– Pascal Hofmann2019-11-12 10:30:20 +00:00CommentedNov 12, 2019 at 10:30
As of now (2022) Sonatype Nexus3 only supports high availability through what they call "cloud resilient single-node deployment", which translates to a 1-replica k8s deployment. In this scenario it is Kubernetes that provides resiliency as it will replicate the pod in case of issues with the pod, the k8s cluster node, or the entire availability zone/datacenter.
There's no support for active/active redundant instances of Nexus3, even in the Pro version. Currently Nexus is in version 3.41. They say in their websie, thought, that they have plans to implement clustering HA (active/active).
Smart proxying is not a feature of Nexus3 and the link for "Component fabric" is broken. I assume they removed this feature.
Also they say in their website that HA requires a paid version (Nexus Pro and not Nexus OSS) but I think that this is inaccurate, since as long as it's k8s that is providing the resiliency, it works for both OSS and Pro versions.
Explore related questions
See similar questions with these tags.

