Welcome to the new Gigaspaces XAP forum. To recover your account, please follow these instructions.

Ask Your Question
0

How to scale more number of servers?

Currently we have 2 gs-agents running in two servers and we are using LOOKUPLOCATORS variable to set the Machine IP addresses (in both the servers) in order to communicate each other.

My Questions is: If I am going to add one or more server then I need to add IP address in all the server's LOOKUPLOCATORS variable? Is there any way to do by referring any properties file ? or we need to configure the IP Address of all the machines?

Note: In my network the multicast may or may not be enabled. So I am using unicast discovery using LOOKUPLOCATORS .

{quote}This thread was imported from the previous forum. For your reference, the original is [available here|http://forum.openspaces.org/thread.jspa?threadID=4116]{quote}

asked 2013-06-27 09:58:03 -0600

get4gopim gravatar image

updated 2013-08-08 09:52:00 -0600

jaissefsfex gravatar image
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

LOOKUPLOCATORS should be used to identify machines running the lookup service when using the unicast discovery approach. You should not have more than 2 machines running a lookup service.
GSCs and GSMs using the LOOKUPLOCATORS variable to find the lookup service(s). Clients using the locators property when searching for the lookup service (part of the space URL). If you use spring (pu.xml) to configure your client there is a relevant property you can use with the space URL bean to set the locator value.

If you add a new server to run more GSCs (to scale your data grid to run more partitions to be provisioned across more GSCs and more machines) you don't need to run another lookup service. Just have the same LOOKUPLOCATORS value set on the new server.

This will allow the newly started GSCs to introduce themselves to the lookup service , to be used by the GSM when deploying the data grid. The GSM distribute the data grid partitions based on available GSCs (static data grid) or create such dynamically when using the Elastic PU (dynamic elastic data grid).

Shay

answered 2013-06-27 10:20:05 -0600

shay hassidim gravatar image
edit flag offensive delete link more

Comments

Let me explain more on this:

I have two servers: 135.122.99.80 (80 Machine), 135.122.99.81 (81 Machine)

80 Server will have the below applications: GS Agent Running Admin Application Web Service Application

81 Server will have the below application: (this setup I am going to increase in many servers) GS Agent Running Web Service Application

In 80 Server, I have deployed the space (mySpace)

Deploy CLI:

./gs.sh deploy-space -max-instances-per-vm 1 -max-instances-per-machine 1 -cluster schema=partitioned-sync2backup total_members=1,1 mySpace

Starting GS Agent:

./gs-agent.sh

In the gigaspaces setenv.sh file I have the variable (in both the servers) LOOKUPLOCATORS=135.122.99.80, 135.122.99.81

In the applications I using the jini space url and locators variable (lookup.Servers) <os-core:space id="mySpace" url="jini://*/*/mySpace?locators=${lookup.Servers}" schema="cache" versioned="true"/>

The above configuration is working fine with failover and normal cases.

Now my requirement is to increase the number of servers (same as 81 setup). Say for example, Introducing new server (135.122.99.82).

So I have to start the gs-agent for new server like below: ./gs-agent.sh gsa.lus 0 gsa.gsm 0 gsa.gsc 2

Question: If both the servers (135.122.99.80, 135.122.99.81) are down then the third server (135.122.99.82) will be able to pickup? If so what i need to do?

get4gopim gravatar imageget4gopim ( 2013-06-28 03:21:28 -0600 )edit

If both 80 and 81 servers are down you will need the third server to run the lookup service.

By default the agents will run the lookup service on the first 2 servers as they run a global lookup service configuration. This assumes the lookup discovery done via multicast as global means the lookup service can can anywhere on the network.

Since multicast is not enabled on your environment , you will have to use the LOOKUPLOCATORS to specify the servers that will run the lookup service. This is not ideal in cases you might need to add a new server that will run also the lookup service since your LOOKUPLOCATORS will have to list all existing and future machines (IP , or hostname) that will run the lookup service at the system bootstrap.

In this case you will have to run the following with every server to instruct the agent to run a local lookup service and not a global one: {code} gs-agent.(sh/bat) gsa.global.lus 0 gsa.lus 1 {code}

The problem with this approach you will have a lookup on each server so you will exceed the two lookups that is the recommended number of lookups.

I suggest you enable multicast to avoid using the LOOKUPLOCATORS and use the global lookup configuration. It will make your system more dynamic as the agents will make sure you will have 2 lookup services running (as long as you have 2 servers). You won't need to specify the locators as part of the URL.

See more: http://wiki.gigaspaces.com/wiki/displ...

Shay

shay hassidim gravatar imageshay hassidim ( 2013-06-28 09:51:11 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2013-06-27 09:58:03 -0600

Seen: 67 times

Last updated: Jun 27 '13