Edit bin/catalina.sh, and set JAVA_OPTS early in the file (there are no heap size setting in that file, or at least I didn't see one, so there is no line to edit as in other run scripts)
Thanks , it works .
my JVM status now shows
Free memory: 204.15 MB
Total memory: 245.37 MB
Max memory: 245.37 MB
A trivial question I guess where to now the permgen status?
Operating system tools are useless for determining JVM memory usage. The numbers that you printed include (most of the) heap, permgen, the binary code needed to run the JVM, the stacks and other misc non-Java stuff.
If you want to know what is really going on use a tool such a jconsole of virtualvm. Those tools connect to a running JVM and can report heap and permgen usage.
Another question ,
Which is the prefered way of setting the memory setting in jbossweb as a service using etc/init.d/ script, either using CATALINA_OPTS="-Xms256M -Xmx1000M" or the setting JAVA_OPTS in bin/catalina.sh ?
I also sometime saw somewhere the CATALINA_OPTS being set in the bash profile environment file. Of course , in start as a service /auto start on boot context.