cleanest way to restart jboss using a script

Saqib Ali picture Saqib Ali · Jan 24, 2013 · Viewed 32.2k times · Source

I am using " ./standalone.sh -c standalone-full.xml " to start JBOSS. What is the cleanest way to restart jboss in this case? Any scripts that you can share?

Answer

wbdarby picture wbdarby · Sep 24, 2014

@Petr Mensik's solution works well if you need to shutdown the server. But if you need to restart it in a single operation you can use:

jboss-cli.sh -c ":shutdown(restart=true)"

Thanks to these excellent JBoss notes.