Skip to content

Commit f142867

Browse files
committed
[SPARK-8776] Increase the default MaxPermSize
I am increasing the perm gen size to 256m. https://issues.apache.org/jira/browse/SPARK-8776 Author: Yin Huai <[email protected]> Closes #7196 from yhuai/SPARK-8776 and squashes the following commits: 60901b4 [Yin Huai] Fix test. d44b713 [Yin Huai] Make sparkShell and hiveConsole use 256m PermGen size. 30aaf8e [Yin Huai] Increase the default PermGen size to 256m. (cherry picked from commit f743c79) Signed-off-by: Yin Huai <[email protected]>
1 parent de08024 commit f142867

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

launcher/src/main/java/org/apache/spark/launcher/AbstractCommandBuilder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ void addPermGenSizeOpt(List<String> cmd) {
133133
}
134134
}
135135

136-
cmd.add("-XX:MaxPermSize=128m");
136+
cmd.add("-XX:MaxPermSize=256m");
137137
}
138138

139139
void addOptionString(List<String> cmd, String options) {

launcher/src/test/java/org/apache/spark/launcher/SparkSubmitCommandBuilderSuite.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ private void testCmdBuilder(boolean isDriver) throws Exception {
194194
if (isDriver) {
195195
assertEquals("-XX:MaxPermSize=256m", arg);
196196
} else {
197-
assertEquals("-XX:MaxPermSize=128m", arg);
197+
assertEquals("-XX:MaxPermSize=256m", arg);
198198
}
199199
}
200200
}

project/SparkBuild.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ object SparkBuild extends PomBuild {
206206
fork := true,
207207
outputStrategy in run := Some (StdoutOutput),
208208

209-
javaOptions ++= Seq("-Xmx2G", "-XX:MaxPermSize=1g"),
209+
javaOptions ++= Seq("-Xmx2G", "-XX:MaxPermSize=256m"),
210210

211211
sparkShell := {
212212
(runMain in Compile).toTask(" org.apache.spark.repl.Main -usejavacp").value
@@ -307,7 +307,7 @@ object SQL {
307307
object Hive {
308308

309309
lazy val settings = Seq(
310-
javaOptions += "-XX:MaxPermSize=1g",
310+
javaOptions += "-XX:MaxPermSize=256m",
311311
// Specially disable assertions since some Hive tests fail them
312312
javaOptions in Test := (javaOptions in Test).value.filterNot(_ == "-ea"),
313313
// Multiple queries rely on the TestHive singleton. See comments there for more details.

0 commit comments

Comments
 (0)