Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
apollo
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
openSource
apollo
Commits
bca2f6d9
Commit
bca2f6d9
authored
May 26, 2017
by
nobodyiam
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
support running in Git Bash on Windows
parent
041de90d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
60 additions
and
12 deletions
+60
-12
startup.sh
apollo-adminservice/src/main/scripts/startup.sh
+20
-4
startup.sh
apollo-configservice/src/main/scripts/startup.sh
+20
-4
startup.sh
apollo-portal/src/main/scripts/startup.sh
+20
-4
No files found.
apollo-adminservice/src/main/scripts/startup.sh
View file @
bca2f6d9
...
...
@@ -6,17 +6,33 @@ LOG_DIR=/opt/logs/100003172
SERVER_PORT
=
8090
## Adjust memory settings if necessary
export
JAVA_OPTS
=
"-server -Xms2560m -Xmx2560m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=1024m -XX:MaxNewSize=1024m -XX:SurvivorRatio=22"
#export JAVA_OPTS="-Xms2560m -Xmx2560m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=1024m -XX:MaxNewSize=1024m -XX:SurvivorRatio=22"
## Only uncomment the following when you are using server jvm
#export JAVA_OPTS="$JAVA_OPTS -server -XX:-ReduceInitialCardMarks"
########### The following is the same for configservice, adminservice, portal ###########
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:
-ReduceInitialCardMarks -XX:
+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-Dserver.port=
$SERVER_PORT
-Dlogging.file=
$LOG_DIR
/
$SERVICE_NAME
.log -Xloggc:
$LOG_DIR
/heap_trace.txt -XX:HeapDumpPath=
$LOG_DIR
/HeapDumpOnOutOfMemoryError/"
PATH_TO_JAR
=
$SERVICE_NAME
".jar"
SERVER_URL
=
"http://localhost:
$SERVER_PORT
"
if
[[
-z
"
$JAVA_HOME
"
&&
-d
/usr/java/latest/
]]
;
then
export
JAVA_HOME
=
/usr/java/latest/
if
[
"
$(
uname
)
"
==
"Darwin"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"Linux"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"MINGW"
]
;
then
windows
=
"1"
else
windows
=
"0"
fi
# for Windows
if
[
"
$windows
"
==
"1"
]
&&
[[
-n
"
$JAVA_HOME
"
]]
&&
[[
-x
"
$JAVA_HOME
/bin/java"
]]
;
then
tmp_java_home
=
`
cygpath
-sw
"
$JAVA_HOME
"
`
export
JAVA_HOME
=
`
cygpath
-u
$tmp_java_home
`
echo
"Windows new JAVA_HOME is:
$JAVA_HOME
"
fi
cd
`
dirname
$0
`
/..
...
...
apollo-configservice/src/main/scripts/startup.sh
View file @
bca2f6d9
...
...
@@ -6,17 +6,33 @@ LOG_DIR=/opt/logs/100003171
SERVER_PORT
=
8080
## Adjust memory settings if necessary
export
JAVA_OPTS
=
"-server -Xms6144m -Xmx6144m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=4096m -XX:MaxNewSize=4096m -XX:SurvivorRatio=18"
#export JAVA_OPTS="-Xms6144m -Xmx6144m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=4096m -XX:MaxNewSize=4096m -XX:SurvivorRatio=18"
## Only uncomment the following when you are using server jvm
#export JAVA_OPTS="$JAVA_OPTS -server -XX:-ReduceInitialCardMarks"
########### The following is the same for configservice, adminservice, portal ###########
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:
-ReduceInitialCardMarks -XX:
+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-Dserver.port=
$SERVER_PORT
-Dlogging.file=
$LOG_DIR
/
$SERVICE_NAME
.log -Xloggc:
$LOG_DIR
/heap_trace.txt -XX:HeapDumpPath=
$LOG_DIR
/HeapDumpOnOutOfMemoryError/"
PATH_TO_JAR
=
$SERVICE_NAME
".jar"
SERVER_URL
=
"http://localhost:
$SERVER_PORT
"
if
[[
-z
"
$JAVA_HOME
"
&&
-d
/usr/java/latest/
]]
;
then
export
JAVA_HOME
=
/usr/java/latest/
if
[
"
$(
uname
)
"
==
"Darwin"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"Linux"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"MINGW"
]
;
then
windows
=
"1"
else
windows
=
"0"
fi
# for Windows
if
[
"
$windows
"
==
"1"
]
&&
[[
-n
"
$JAVA_HOME
"
]]
&&
[[
-x
"
$JAVA_HOME
/bin/java"
]]
;
then
tmp_java_home
=
`
cygpath
-sw
"
$JAVA_HOME
"
`
export
JAVA_HOME
=
`
cygpath
-u
$tmp_java_home
`
echo
"Windows new JAVA_HOME is:
$JAVA_HOME
"
fi
cd
`
dirname
$0
`
/..
...
...
apollo-portal/src/main/scripts/startup.sh
View file @
bca2f6d9
...
...
@@ -6,17 +6,33 @@ LOG_DIR=/opt/logs/100003173
SERVER_PORT
=
8080
## Adjust memory settings if necessary
export
JAVA_OPTS
=
"-server -Xms4096m -Xmx4096m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=1536m -XX:MaxNewSize=1536m -XX:SurvivorRatio=22"
#export JAVA_OPTS="-Xms4096m -Xmx4096m -Xss256k -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=384m -XX:NewSize=1536m -XX:MaxNewSize=1536m -XX:SurvivorRatio=22"
## Only uncomment the following when you are using server jvm
#export JAVA_OPTS="$JAVA_OPTS -server -XX:-ReduceInitialCardMarks"
########### The following is the same for configservice, adminservice, portal ###########
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:
-ReduceInitialCardMarks -XX:
+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-XX:+UseParNewGC -XX:ParallelGCThreads=4 -XX:MaxTenuringThreshold=9 -XX:+UseConcMarkSweepGC -XX:+DisableExplicitGC -XX:+UseCMSInitiatingOccupancyOnly -XX:+ScavengeBeforeFullGC -XX:+UseCMSCompactAtFullCollection -XX:+CMSParallelRemarkEnabled -XX:CMSFullGCsBeforeCompaction=9 -XX:CMSInitiatingOccupancyFraction=60 -XX:+CMSClassUnloadingEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:+CMSPermGenSweepingEnabled -XX:CMSInitiatingPermOccupancyFraction=70 -XX:+ExplicitGCInvokesConcurrent -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCApplicationConcurrentTime -XX:+PrintHeapAtGC -XX:+HeapDumpOnOutOfMemoryError -XX:-OmitStackTraceInFastThrow -Duser.timezone=Asia/Shanghai -Dclient.encoding.override=UTF-8 -Dfile.encoding=UTF-8 -Djava.security.egd=file:/dev/./urandom"
export
JAVA_OPTS
=
"
$JAVA_OPTS
-Dserver.port=
$SERVER_PORT
-Dlogging.file=
$LOG_DIR
/
$SERVICE_NAME
.log -Xloggc:
$LOG_DIR
/heap_trace.txt -XX:HeapDumpPath=
$LOG_DIR
/HeapDumpOnOutOfMemoryError/"
PATH_TO_JAR
=
$SERVICE_NAME
".jar"
SERVER_URL
=
"http://localhost:
$SERVER_PORT
"
if
[[
-z
"
$JAVA_HOME
"
&&
-d
/usr/java/latest/
]]
;
then
export
JAVA_HOME
=
/usr/java/latest/
if
[
"
$(
uname
)
"
==
"Darwin"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"Linux"
]
;
then
windows
=
"0"
elif
[
"
$(
expr
substr
$(
uname
-s
)
1 5
)
"
==
"MINGW"
]
;
then
windows
=
"1"
else
windows
=
"0"
fi
# for Windows
if
[
"
$windows
"
==
"1"
]
&&
[[
-n
"
$JAVA_HOME
"
]]
&&
[[
-x
"
$JAVA_HOME
/bin/java"
]]
;
then
tmp_java_home
=
`
cygpath
-sw
"
$JAVA_HOME
"
`
export
JAVA_HOME
=
`
cygpath
-u
$tmp_java_home
`
echo
"Windows new JAVA_HOME is:
$JAVA_HOME
"
fi
cd
`
dirname
$0
`
/..
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment