Thanks for sharing this. For information like this, the community wiki (which every registered user, including you, is provided write access) http://www.jboss.org/community/wiki/ is the best place to share such information.
For example here http://www.jboss.org/community/wiki/JBoss5FAQ. Feel free to add this or any such informative articles to the wiki.
We did not use %JBOSS_DIST%\bin\service.bat
Just a FYI - If the service.bat was used, it would have handled this specific case, since it specifically sets this param:
but unfortunately, in it's current form leads to a different issue https://jira.jboss.org/jira/browse/JBAS-7290