I want to set up WSO2 Identity Server cluster and an other for WSO2 API Manager. Identity server will be used to enable SSO for our applications and also to register existing Identity Providers (ex: ADFS). API Manager will be used to manage our Rest API's and to provide them to our applications. I also want to configure the Identity Server to be the Key Manager.
As the documentation says for WSO2 Cluster deployment, Management nodes are specialized in management of the setup, while worker nodes are specialized in serving requests to deployment artifacts. Besides that, API Manager product provides 5 diferent profiles (key-manager, publisher, store, gateway-manager and gateway-worker).
For now, I have 3 servers (server1, server2 and server3) in which I will install and configure the WSO2 Cluster nodes for Identiy Server and API Manager. I also created a load balancer that will be used to forward requests for each cluster nodes (IS and AM).
After some reading, I concluded that I would need to install WSO2 IS and WSO2 AM as manager nodes on the server1 and the two other servers would be used as worker nodes.
I think I already managed to install and configure Identity Server cluster, the url mgt.identity.mydomain.pt points to the server1 node and identity.mydomain.pt points to server2 and server3 nodes for load balancing requests.
Now I'm stuck with API manager cluster configuration, I want to use server2 and server3 as the gateway to load balance requests (apis.mydomain.pt) for our Rest API's and use server1 to manage our API's using store and publiser components (mgt.apis.mydomain.pt). I'm struggling to understand which profile I have to use for each nodes. I tried to install a manager node on server1 with the default profile and install worker nodes on the server2 and server3 with the gateway-worker profile but I'm getting errors related to the Deployment Synchronizer (error logs). I guess I am doing something wrong because those errors only shows up when using the gateway-worker profile.
Anyone can explain me the difference between worker and manager nodes and how they are related with wso2 profiles?
UPDATE:
I found out what I was missing and was causing the error. I was starting the server2 and server3 just with -Dprofile=gateway-worker, I added -DworkerNode=true and I have no errors in log anymore.
Anyway, I am still a little bit confused about using the gateway-manager and gateway-worker profiles.
https://docs.wso2.com/display/CLUSTER44x/Configuring+SVN-Based+Deployment+Synchronizer contains Deployment synchronizer related configurations. Can you check whether you configured the manager and worker nodes correctly
Related
I like to installing wso2 api manager in a cluster.Is it possible to create two api manager server in same cluster.
You can configure 2 API Manager nodes in Active-Active. Both starts accepting traffic routing, API creation, etc.
Please refer -
https://apim.docs.wso2.com/en/latest/install-and-setup/setup/single-node/configuring-an-active-active-deployment/#configuring-an-active-active-deployment
I am new to WSO2 product. I have setup WSO2 ESB cluster. Servers comes up nicely but configuration done on server1 doesn't gets reflected to server2, say, I created datasource on server1, but it doesn't shows up on second server in cluster.
I'm trying to understand WSO2 APIM components and deployment scenarios but the terminology is confusing/vague for me. Clustering vs distributed deployments, profiles, and Port Offsets.
Basically I'd like to deploy a minimal 5 node setup where:
Node # (Location) Purpose
(DMZ) the GW (worker=True right?) and KeyManager
(DMZ) 2nd GW node (as above) for GW & KeyManager
(non-dmz) the Management Console, MySQL master
(non-dmz) the Publisher UI,TrafficManager, MySQL slave
(DMZ) the Store
Questions:
Should I use -DportOffset=0 on all nodes?
What -Dprofile=?? do I need to use on each of the 5 nodes?
The 2 gateway nodes will be load-balanced by an F5 load balancer
for incoming api-traffic. What port is used there, 9443 or 9763?
What ports need to be accessible on the DMZ hosts for this to work?
I assume 3306,9443,9763,8280,8243,7711, and 9999,11111 if JMX reqd
Please don't point me to the documentation, that's what is confusing me.
Running the key manager nodes, Store node in the DMZ is not recommended as they need db access. If you are using multi tenancy, you cannot host gateway worker nodes in the DMZ as well due to db access. What you can do is host those nodes in LAN and have a reverse proxy in the DMZ to expose the endpoints on the Gateway and Store. If you do not use multi tenancy, then you can run gateway worker nodes in the DMZ as dbs are not used.
As you are running multiple WSO2 servers in a single server you need to use port offsets to avoid conflicts. Default port offset is 0. You can run one WSO2 server with default port offset. For the other server you need to use port offset 1 or any value other than 0. You can start the server by giving the -DportOffset=1 at the startup. Best way is to change the value offset to 1 in /repository/conf/carbon.xml so that you do not need to provide the -DportOffset value at the startup.
-Dprofile is denote the profile which API Manager should start. If you start with -Dprofile=api-publisher, it would only starts the front end/backend features relevant to the API Publisher. Running product profiles are mostly recommended as it would only load relevant features of the profile. You can use profiles in your deployment as you are running 6 profiles of API Manager.
I think you are referring gateway worker nodes which serve API traffic. If so, it will use passthrough ports that are 8280(http) and 8243(https). Requests can serve using both. 9443 and 9763 are servlet ports are those will not used in gateway worker nodes and only in gateway manager node for service calls.
My recommendation is you should revise this setup as you are running nodes in DMZ which have db access.
Should I use -DportOffset=0 on all nodes?
It depends on how do you set up those nodes. If all of these servers in the same node (machine), you must use different port offset as all the API Manager servers use those port, so, there will be port conflicts.
What -Dprofile=?? do I need to use on each of the 5 nodes?
It will adjust the ports used by API Manager so that, there won't be any port conflicts between them if you are running on same node.
The 2 gateway nodes will be load-balanced by an F5 load balancer for
incoming api-traffic. What port is used there, 9443 or 9763?
For API requests/responses handling, you need 9763.
What ports need to be accessible on the DMZ hosts for this to work? I
assume 3306,9443,9763,8280,8243,7711, and 9999,11111 if JMX reqd
Yes, it's correct.
Further, you can use WSO2 support any issues you encountered.
We are planning to try out WSO2 Greg and wanted to know if we use external hardware load balancer, do we still need to configure manager + worker node configuration or we can start two standalone instances connecting to same back end i.e. oracle database and load balance it via front end external load balancer?
Thanks
You can use a third-party load balancer for WSO2 GREG cluster. You do not have to use manager/worker configuration for Axis2 clustering (subDomain property) as we use with WSO2 ELB.
You will still have to configure Axis2 clustering without subDomain property. I would recommend you to use wka membership scheme and nominate few nodes as wka members in the cluster.
I want to make a cluster of Data Services Servers(DSS), and use an Enterprise Service Bus (ESB) as load balancer. In this deployment, what is the purpose of having a manager DSS in the cluster, and if there is a manager, is it a single point of failure?
These are the references which I used for load balancing and DSS clustering:
Dynamic load balancing between 3 nodes
How to install WSO2 Carbon cluster management feature?
The dynamic load balancing mechanism in WSO2 ESB, discovers the DSS members in an application group using a group communication framework and shares the load in runtime.
Load balancer is not bound or coupled to any cluster manager - it will simply distribute the load among nodes in applicationDomain.
So - in runtime - cluster manager doesn't create any single point of failure.
If you want you can setup a DSS cluster even without a cluster manager and distribute the load among the nodes via ESB.
The cluster manager - which is a component installed only to manage your cluster...
This is an extension to Prabath's answer.
DSS can be configured to work in a cluster. So that all DSS nodes act as members in a single cluster. This facilitates sharing session among each of the nodes.
Or else, you can have all DSS nodes running in isolation (using the same configuration), fronted by a load balancer (LB). Unlike the previous approach, this method does not support share sessions between DSS nodes. Thus only supports stateless services.
WSO2 ESB can act as a LB. But having a single instance of LB will make it a SPoF. And, LB can be configured to run in a cluster as well.
I don't know what's behind the decision of using an ESB instead of an ELB for LB, but it's up to you which one to use.
The manager is not a single point of failure, it's just a way to manage the entire cluster from a single management console (with limitations), and can be configured to be a worker at the same time.
Regarding the LB layer, you can use keepalived to avoid having a SPoF in the ESB acting as a LB, the same way it's done for WSO2 ELB's.
Take a look on that Failover for ELB with keepalived