SET-UP:
_________________________________________________________________________________________________________________________________________
====================
== JDK ==
====================
1. unzip
/home/work/install/jdk-6u25-linux-x64.bin
2. change path
mv /home/work/install/jdk1.6.0_25 /home/work/tools/jdk1.6.0_25
3. env-param
a. vi /home/work/.bash_profile
b. add params:
_________________________________________________________________
export JAVA_HOME=/home/work/tools/jdk1.6.0_25
export PATH=$PATH:$JAVA_HOME/bin
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export JAVA_HOME PATH CLASSPATH
_________________________________________________________________
c. refresh env-params
source .bash_profile
_________________________________________________________________________________________________________________________________________
====================
== TOMCAT ==
====================
the tomcat[/home/work/install/tomcat-7.0.56-template] is template of deploy-container.
if u want to create a new app-deploy with tomcat, u can do these after this :
1. copy the tomcat to your path
such as : cp -r /home/work/apache-tomcat-7.0.56/ /home/work/app/tomcat_8030_common_rpc/
2. config your app's serverPort&deployPath in server.xml
a. vi /home/work/app/tomcat_8030_common_rpc/conf/server.xml
b. <Server port="7030" shutdown="SHUTDOWN"> (shutdown-port should be use 70XX)
c. <Connector port="8443" protocol="org.apache.coyote.http11.Http11Protocol" (http-port should be use 80XX)
d. <Connector port="9030" protocol="AJP/1.3" redirectPort="8443" /> (ajp-port should be use 90XX,not use now)
e. <Host name="localhost" appBase="/home/work/local/common_rpc" (deploy-appBase)
3. config your app's env-param in setenv.sh
a. vi /home/work/apache-tomcat-7.0.56/bin/setenv.sh
b. add your env-param into shell
such as:
JAVA_OPTS="$JAVA_OPTS\
-server\
-XX:PermSize=512M\
-XX:MaxPermSize=1024M\
-Dbdyx.sys.server.type=rdtest\
-Dbdyx.sys.logger.path=$CATALINA_HOME/logs\
-DserverName=first\
-Didc=m1"
_________________________________________________________________________________________________________________________________________
====================
== MEMCACHED ==
====================
1. libevent (required)
a. wget http://monkey.org/~provos/libevent-1.4.14b-stable.tar.gz
b. tar zxvf libevent-1.4.14b-stable.tar.gz
c. cd libevent-1.4.14b-stable
d. ./configure --prefix=/home/work/tools/libevent
e. make clean all
f. make install
2. memcached
a. wget http://memcached.googlecode.com/files/memcached-1.4.5.tar.gz
b. tar zxvf memcached-1.4.5.tar.gz
c. cd memcached-1.4.5
d. ./configure --prefix=/home/work/tools/memcached-1.4.5 --with-libevent=/home/work/tools/libevent
e. make
f. make install
3. LD_LIBRARY_PATH (if u start memcached,and error: error while loading shared libraries: libevent-1.4.so.2: cannot open shared object file: No such file or directory)
a. vi /home/work/.bash_profile
b. export LD_LIBRARY_PATH=/home/work/tools/libevent/lib:$LD_LIBRARY_PATH
4. server startup
/home/work/tools/memcached-1.4.5/bin/memcached -d -m 4096 -l 10.205.135.45 -p 11211 -u work -c 2048
_________________________________________________________________________________________________________________________________________
====================
== REDIS ==
====================
1. install
a. unzip redis-2.8.8.tar.gz > $redis_home
b. enter $redis_home & make
2. server-start
$redis_home/src/redis-server redis_6379.conf
3. client
$redis_home/src/redis-cli -p 6379 -a password
_________________________________________________________________________________________________________________________________________
====================
== ACTIVEMQ ==
====================
1. unzip
tar -zxvf /home/work/install/activemq5.5.tar.gz /home/work/tools/activemq-5.5
2. configuration(datasouce)
vi /home/work/tools/activemq-5.5/conf/credentials.properties
3. server start
/home/work/tools/activemq-5.5/bin/activemq start
4. monitor-url(admin/admin)
http://localhost:8161/admin
5. server shutdown
/home/work/tools/activemq-5.5/bin/activemq stop
remark:
add mysql-visit-privileges:
1. GRANT ALL PRIVILEGES ON *.* TO 'root'@'10.205.135.45' IDENTIFIED BY '123456' WITH GRANT OPTION;
2. FLUSH PRIVILEGES ;
_________________________________________________________________________________________________________________________________________
_________________________________________________________________________________________________________________________________________
====================
== JDK ==
====================
1. unzip
/home/work/install/jdk-6u25-linux-x64.bin
2. change path
mv /home/work/install/jdk1.6.0_25 /home/work/tools/jdk1.6.0_25
3. env-param
a. vi /home/work/.bash_profile
b. add params:
_________________________________________________________________
export JAVA_HOME=/home/work/tools/jdk1.6.0_25
export PATH=$PATH:$JAVA_HOME/bin
export CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar
export JAVA_HOME PATH CLASSPATH
_________________________________________________________________
c. refresh env-params
source .bash_profile
_________________________________________________________________________________________________________________________________________
====================
== TOMCAT ==
====================
the tomcat[/home/work/install/tomcat-7.0.56-template] is template of deploy-container.
if u want to create a new app-deploy with tomcat, u can do these after this :
1. copy the tomcat to your path
such as : cp -r /home/work/apache-tomcat-7.0.56/ /home/work/app/tomcat_8030_common_rpc/
2. config your app's serverPort&deployPath in server.xml
a. vi /home/work/app/tomcat_8030_common_rpc/conf/server.xml
b. <Server port="7030" shutdown="SHUTDOWN"> (shutdown-port should be use 70XX)
c. <Connector port="8443" protocol="org.apache.coyote.http11.Http11Protocol" (http-port should be use 80XX)
d. <Connector port="9030" protocol="AJP/1.3" redirectPort="8443" /> (ajp-port should be use 90XX,not use now)
e. <Host name="localhost" appBase="/home/work/local/common_rpc" (deploy-appBase)
3. config your app's env-param in setenv.sh
a. vi /home/work/apache-tomcat-7.0.56/bin/setenv.sh
b. add your env-param into shell
such as:
JAVA_OPTS="$JAVA_OPTS\
-server\
-XX:PermSize=512M\
-XX:MaxPermSize=1024M\
-Dbdyx.sys.server.type=rdtest\
-Dbdyx.sys.logger.path=$CATALINA_HOME/logs\
-DserverName=first\
-Didc=m1"
_________________________________________________________________________________________________________________________________________
====================
== MEMCACHED ==
====================
1. libevent (required)
a. wget http://monkey.org/~provos/libevent-1.4.14b-stable.tar.gz
b. tar zxvf libevent-1.4.14b-stable.tar.gz
c. cd libevent-1.4.14b-stable
d. ./configure --prefix=/home/work/tools/libevent
e. make clean all
f. make install
2. memcached
a. wget http://memcached.googlecode.com/files/memcached-1.4.5.tar.gz
b. tar zxvf memcached-1.4.5.tar.gz
c. cd memcached-1.4.5
d. ./configure --prefix=/home/work/tools/memcached-1.4.5 --with-libevent=/home/work/tools/libevent
e. make
f. make install
3. LD_LIBRARY_PATH (if u start memcached,and error: error while loading shared libraries: libevent-1.4.so.2: cannot open shared object file: No such file or directory)
a. vi /home/work/.bash_profile
b. export LD_LIBRARY_PATH=/home/work/tools/libevent/lib:$LD_LIBRARY_PATH
4. server startup
/home/work/tools/memcached-1.4.5/bin/memcached -d -m 4096 -l 10.205.135.45 -p 11211 -u work -c 2048
_________________________________________________________________________________________________________________________________________
====================
== REDIS ==
====================
1. install
a. unzip redis-2.8.8.tar.gz > $redis_home
b. enter $redis_home & make
2. server-start
$redis_home/src/redis-server redis_6379.conf
3. client
$redis_home/src/redis-cli -p 6379 -a password
_________________________________________________________________________________________________________________________________________
====================
== ACTIVEMQ ==
====================
1. unzip
tar -zxvf /home/work/install/activemq5.5.tar.gz /home/work/tools/activemq-5.5
2. configuration(datasouce)
vi /home/work/tools/activemq-5.5/conf/credentials.properties
3. server start
/home/work/tools/activemq-5.5/bin/activemq start
4. monitor-url(admin/admin)
http://localhost:8161/admin
5. server shutdown
/home/work/tools/activemq-5.5/bin/activemq stop
remark:
add mysql-visit-privileges:
1. GRANT ALL PRIVILEGES ON *.* TO 'root'@'10.205.135.45' IDENTIFIED BY '123456' WITH GRANT OPTION;
2. FLUSH PRIVILEGES ;
_________________________________________________________________________________________________________________________________________