0

running windows this is what I have in my jenkins.xml file:

  <executable>%BASE%\jre\bin\java</executable>
  <arguments> -Xrs -Xmx1024m -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle -Djenkins.branch.WorkspaceLocatorImpl.PATH_MAX=25 -Dhudson.model.DirectoryBrowserSupport.CSP="sandbox allow-scripts allow-same-origin; default-src 'none'; img-src 'self' data: ; style-src 'self' 'unsafe-inline' data: ; script-src 'self' 'unsafe-inline' 'unsafe-eval';" -jar "%BASE%\jenkins.war" --httpPort=-1 --httpsPort=443 --httpsKeyStore="C:\keys\keystore" --httpsKeyStorePassword="mypass" --webroot="%BASE%\war" </arguments>

If I try changing increasing the Xmx setting or adding an Xms setting the jenkins service refuses to start. I have to change it to exactly -Xmx1024m. Why could this be?

red888
  • 27,709
  • 55
  • 204
  • 392
  • When you say refuses to start, can you post the message you are getting? If you're on windows try checking the EventViewer – dann.dev Jan 18 '18 at 21:18
  • [This](https://stackoverflow.com/questions/5936519/how-to-give-jenkins-more-heap-space-when-it%C2%B4s-started-as-a-service-under-windows) as well as the linked article in the answer might help. – JGlass Jan 18 '18 at 21:31
  • Its not letting me edit Xmx1024m from this value. Also, I see no examples there for setting Xms – red888 Jan 18 '18 at 21:32
  • Sorry about that, is it used in conjunction with Ant? People had luck increasing the amount for ANT which in turn apparently affected (positively) the Jenkins results – JGlass Jan 18 '18 at 21:44
  • I'm not sure if vanilla jenkins windows install uses ant. Maybe it just doesn't support Xms? honestly i haven't got any memory errors so that might not even be an issue I just don't get why it doesn't like me changing it. I couldn't find anything useful in the jenkins err log. – red888 Jan 18 '18 at 21:51

0 Answers0