Skip to content

Latest commit

 

History

History
80 lines (63 loc) · 2.88 KB

README-lattice.adoc

File metadata and controls

80 lines (63 loc) · 2.88 KB

WAN-Analytics-IoT

Lattice - Setup

$ mkdir /tmp

Geode Locator

$ ltc create locator markito/geode-docker-spark --run-as-root -m "0" --working-dir=/tmp --monitor-port=10334 -p 10334,1099  -- gfsh start locator --name=loc1  --mcast-port=0 --J=-Djmx-manager-start=false

Verify the port mapping for 10334:

$ ltc status locator

Geode Server

$ ltc create server markito/geode-docker-spark --run-as-root -m "0" --working-dir=/tmp --monitor-port=40404 -p 40404 -- gfsh start server --name=server1  --locators=192.168.11.11[PORT]

Check if cluster is running

$ltc create gfsh markito/geode-docker-spark  --no-monitor -- gfsh -e "connect --locator=192.168.11.11[PORT]" -e "list members"
(...)

$ltc logs gfsh

07/17 08:20:32.12 [APP|0] (1) Executing - connect --locator=192.168.11.11[61038]
07/17 08:20:32.16 [APP|0] Connecting to Locator at [host=192.168.11.11, port=61038] ..
07/17 08:20:32.66 [APP|0] Connecting to Manager at [host=10.254.0.1, port=1099] ..
07/17 08:20:32.83 [APP|0] Successfully connected to: [host=10.254.0.1, port=1099]
07/17 08:20:32.84 [APP|0] (2) Executing - list members
07/17 08:20:32.88 [APP|0]  Name   | Id
07/17 08:20:32.89 [APP|0] ------- | --------------------------------------
07/17 08:20:32.89 [APP|0] server1 | 10.254.0.5(server1:43)<v1>:43803
07/17 08:20:32.89 [APP|0] loc1    | sd2prfknjf3(loc1:42:locator)<v0>:59255
07/17 08:20:33.00 [APP|0] Exit status 0

Running GFSH in the locator container

Find the locator information

  $ curl http://receptor.192.168.11.11.xip.io/v1/actual_lrps/locator
  {"process_guid":"locator","instance_guid":"bb35c005-58f0-4fdc-4d7b-9436ee3fd4c0","cell_id":"cell-01","domain":"lattice","index":0,"address":"192.168.11.11","ports":[{"container_port":10334,"host_port":61001},{"container_port":1099,"host_port":61002}],"state":"RUNNING","crash_count":0,"since":1437157421384273056,"evacuating":false,"modification_tag":{"epoch":"3e694cf2-a051-4613-4fd4-32508a8e3848","index":2}}]

From the lattice installation directory, access the vagrant ssh

  $ vagrant ssh
  Welcome to Ubuntu 14.04.2 LTS (GNU/Linux 3.16.0-30-generic x86_64)
   * Documentation:  https://help.ubuntu.com/
  Last login: Fri Jun 19 13:56:21 2015 from 10.0.2.2
  vagrant@ubuntu-trusty-64:~$

Now move to the garden depot directory and find your container instance.

# cd /var/lattice/garden/depot/
root@ubuntu-trusty-64:/var/lattice/garden/depot# ls
seelq57ubic  seelq57ubid    -- these are the containers for e.g.
# cd seelq57ubic
# bin/wsh
[root@seelq57ubic ~]#

You still need to set JAVA_HOME and the PATH before accessing GFSH.

[root@seelq57ubic ~]# export JAVA_HOME=/jdk1.8.0_45/
[root@seelq57ubic ~]# export GEODE_HOME=/incubator-geode/gemfire-assembly/build/install/apache-geode/
[root@seelq57ubic ~]# export PATH=$PATH:$JAVA_HOME/bin:$GEODE_HOME/bin

Now you can access gfsh by just typing gfsh