美文网首页
《日子》.apache-geode 环境搭建

《日子》.apache-geode 环境搭建

作者: 战神汤姆 | 来源:发表于2016-02-20 14:25 被阅读0次

How to Install

Build from source or use the ZIP or TAR distribution to install Project Geode on every physical and virtual machine that will run Project Geode.

Build from Source

1.Set the JAVA_HOME environment variable. On Linux/Unix platforms:
<code>JAVA_HOME=/usr/java/jdk1.8.0_60export JAVA_HOME</code>
On Windows platforms:
<code>set JAVA_HOME=c:\Program Files\Java\jdk1.8.0_60 </code>
2.Download the project source from the Releases page found at
http://geode.incubator.apache.org.
3.Within the incubator-geode directory, build on Linux/Unix platforms:
<code>$ ./gradlew build installDist -Dskip.tests=true</code>
Within the incubator-geode folder, build on Windows platforms:
<code>$ gradlew.bat build installDist -Dskip.tests=true</code>
4.Verify the installation by invoking gfsh
to print version information and exit. On Linux/Unix platforms:
<code>$ cd gemfire-assembly/build/install/apache-geode
$ gfsh version
v1.0.0-incubating-SNAPSHOT</code>
On Windows platforms:
<code>$ cd gemfire-assembly\build\install\apache-geode
$ gfsh version
v1.0.0-incubating-SNAPSHOT</code>

Install from .zip or .tar File

1.Download the .zip or .tar file from the Releases page found at
http://geode.incubator.apache.org.
2.Unzip the .zip file or expand the .tar file. For the .zip format:
<code>$ unzip gemfire-1.0.0.0-SNAPSHOT.zip -d path_to_product</code>

For the .tar format:
<code>$ tar -xvf gemfire-1.0.0.0-SNAPSHOT.tar -C path_to_product</code>

3.Set the JAVA_HOME environment variable. On Linux/Unix platforms:
<code>JAVA_HOME=/usr/java/jdk1.8.0_60export JAVA_HOME</code>
On Windows platforms:
<code>set JAVA_HOME=c:\Program Files\Java\jdk1.8.0_60</code>

4.Add the Geode scripts to your PATH environment variable. On Linux/Unix platforms:
<code>PATH=$PATH:$JAVA_HOME/bin:path_to_product/bin
export PATH</code>
On Windows platforms:
<code>set PATH=%PATH%;%JAVA_HOME%\bin;%GEMFIRE%\bin</code>

5.This step only applies to environments in which you are running Geode processes or Geode
client applications outside of gfsh. If you are running Geode processes or applications outside
of gfsh, then configure the following two environment variables

.Set the GEMFIRE environment variable to point to your Geode installation top-level
directory. Directories bin, lib, and dtd will be within this top-level directory. On Linux/Unix
platforms:
<code>GEMFIRE=path_to_product
export GEMFIRE</code>
For Windows platforms:
<code>set GEMFIRE=C:*path_to_product*</code>

Set the GF_JAVA environment variables to point to the java
executable relative to the JAVA_HOME environment variable. On Linux/Unix platforms:
<code>GF_JAVA=$JAVA_HOME/bin/javaexport GF_JAVA</code>
On Windows platforms:
<code>set GF_JAVA=%JAVA_HOME%\bin\java.exe</code>

6.To verify the installation, type gfsh version
at the command line and note that the output lists the installed version of Geode. For example:
<code>$ gfsh versionv1.0.0-incubating-SNAPSHOT</code>
For more detailed version information such as the date of the build, build number and JDK
version being used, invoke:
<code>$ gfsh version --full</code>

start

gfsh>start locator --name=locator1 --bind-address=
gfsh>start server --name=server1 --group=group1 --bind-address= start--server-port=40411
gfsh>start server --name=server3
--J=-Xms80m,-Xmx80m --J=-XX:+UseConcMarkSweepGC,-XX:CMSInitiatingOccupancyFraction=65
gfsh>shutdown --include-locators=true

gfsh>create region --name="PR1" --type=PARTITION --redundant-copies=1 --recovery-delay=10000 --startup-recovery-delay=5000

修改gemfire.properties配置文件
enable-network-partition-detection=true
enforce-unique-host=true
redundancy-zone=rack2

start locator --name=locator234 --locators='192.168.70.236[10334],192.168.70.235[10334],192.168.70.234[10334]' --mcast-port=0

start locator --name=locator235 --locators='192.168.70.236[10334],192.168.70.235[10334],192.168.70.234[10334]' --mcast-port=0

start locator --name=locator236 --locators='192.168.70.236[10334],192.168.70.235[10334],192.168.70.234[10334]' --mcast-port=0

start server --name=server237 --locators='192.168.70.234[10334],192.168.70.235[10334],192.168.70.236[10334]' --classpath=/yougola/cluster/geode/classes

start server --name=server238 --locators='192.168.70.234[10334],192.168.70.235[10334],192.168.70.236[10334]' --classpath=/yougola/cluster/geode/classes

start server --name=server239 --locators='192.168.70.234[10334],192.168.70.235[10334],192.168.70.236[10334]' --classpath=/yougola/cluster/geode/classes

相关文章

网友评论

      本文标题:《日子》.apache-geode 环境搭建

      本文链接:https://www.haomeiwen.com/subject/cwxckttx.html