In my startup script (for Ubuntu server 6.10) I need to be able to shutdown the jboss server when the server stops.
However my server's jmx console is secured - because it's a public server.
so shutting it down with the jboss's bin command won't work, unless I hardcode my server password in the init.d file - which I am not allowed.
(the strange thing is I even found this in the red hat scripts - so they don't allow securing the jmx-console either)
After some searching I've found this solution:
su -l jboss -c 'killall java'
So basically I am soft killing all processes of the jboss user. Is this a good practice?
PS: I think jboss is really great, but I find the support for OS services (startup/shutdown) integration on production lacking at this time. I hope the support for production use on Ubuntu, Red Hat, Debian, Suse and even Windows will improve.