Need to increase the heap size for jenkins windows server

Hello All,

We are facing below error in logs due to JVM issue. So, we have changed the size in the jenkins.xml file like below: -

-Xrs -Xmx1024m -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle -jar “%BASE%\jenkins.war” --httpPort=8080 --webroot=“%BASE%\war”

-Xrs -Xmx2048m -XX:MaxPermSize=512m -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle -jar “%BASE%\jenkins.war” --httpPort=8080 --webroot=“%BASE%\war”

But still we are facing issue when we trying to start the jenkins server and we got the below log from windows server “system log” like below:-
Child process [9356 - C:\Program Files (x86)\Jenkins\jre\bin\java -Xrs -Xmx2048m -Dhudson.lifecycle=hudson.lifecycle.WindowsServiceLifecycle -jar “C:\Program Files (x86)\Jenkins\jenkins.war” --httpPort=8080 --webroot=“C:\Program Files (x86)\Jenkins\war” ] finished with 1

Kindly suggest me the process to improve the heap size for jenkins windows?

Can someone respond for this question please.