When starting JBoss as a service $LANG is not preserved
Issue
- The Java system property of sun.jnu.encoding being set to ANSI_X3.4-1968 on prod and UTF-8 on non-prod. The issue is caused by the way that JBoss is started. If "/etc/init.d/jboss start" is called manually then it works fine (which is how JBoss is usually started on non-prod), but if it is started through "/sbin/service Jboss start" then it doesn't. I read that java determines the value of sun.jnu.encoding from the $LANG variable. Calling /etc/init.d/jboss directly results in $LANG being set to en_US.UTF_8, but when it is called through /sbin/service then it is set to nothing/blank.
Environment
- JBoss Enterprise Application Platform (EAP) 5
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
