Re: Giving java apps more memory

2011-11-23 Thread Stuart Henderson
On 2011-11-19, John Tate j...@johntate.org wrote:
 Is this information helpful...

 john@rothbard ~$ ulimit -a
 core file size  (blocks, -c) unlimited
 data seg size   (kbytes, -d) 524288
 file size   (blocks, -f) unlimited
 max locked memory   (kbytes, -l) 1354329
 max memory size (kbytes, -m) 4059940
 open files  (-n) 128
 pipe size(512 bytes, -p) 1
 stack size  (kbytes, -s) 4096
 cpu time   (seconds, -t) unlimited
 max user processes  (-u) 128
 virtual memory  (kbytes, -v) 528384

 I need to change this one in login.conf or in my .profile...
 max memory size (kbytes, -m) 4059940

 There is no manpage for ulimit.

Crank ulimit -d, or datasize-cur (and datasize-max if necessary) in
/etc/login.conf. The defaults may seem a bit on the low side for a single
user system *but* remember this is a multi-user operating system, so there
has to be a balance between single-user usability and protecting a multi-
user system from excessive user demands making the machine unusable...
(Though I do think that maybe the defaults could be increased by a bit).

Be aware that the Java VM bases its heap size on the datasize limit so
you might *not* want to just crank the system limit to something absolutely
huge, it might be more appropriate to just use a higher ulimit -d when you
start specific programs needing more (netbeans/eclipse etc) - you might
also want to look into restricting the heap size on the java command line,
maybe something like -Xmx256m.



Re: Giving java apps more memory

2011-11-22 Thread Christiano F. Haesbaert
On 19 November 2011 02:27, John Tate j...@johntate.org wrote:
 Is this information helpful...

 john@rothbard ~$ ulimit -a
 core file size  (blocks, -c) unlimited
 data seg size   (kbytes, -d) 524288
 file size   (blocks, -f) unlimited
 max locked memory   (kbytes, -l) 1354329
 max memory size (kbytes, -m) 4059940
 open files  (-n) 128
 pipe size(512 bytes, -p) 1
 stack size  (kbytes, -s) 4096
 cpu time   (seconds, -t) unlimited
 max user processes  (-u) 128
 virtual memory  (kbytes, -v) 528384

 I need to change this one in login.conf or in my .profile...
 max memory size (kbytes, -m) 4059940

 There is no manpage for ulimit.


That's cause it is a shell built-in, so its manpage is in ksh(1):
you can always try:
elendil:haesbaert: type ulimit
ulimit is a shell builtin



Re: Giving java apps more memory

2011-11-22 Thread Amit Kulkarni
 Is this information helpful...

 john@rothbard ~$ ulimit -a
 core file size  (blocks, -c) unlimited
 data seg size   (kbytes, -d) 524288
 file size   (blocks, -f) unlimited
 max locked memory   (kbytes, -l) 1354329
 max memory size (kbytes, -m) 4059940
 open files  (-n) 128
 pipe size(512 bytes, -p) 1
 stack size  (kbytes, -s) 4096
 cpu time   (seconds, -t) unlimited
 max user processes  (-u) 128
 virtual memory  (kbytes, -v) 528384

 I need to change this one in login.conf or in my .profile...
 max memory size (kbytes, -m) 4059940

 There is no manpage for ulimit.


 That's cause it is a shell built-in, so its manpage is in ksh(1):
 you can always try:
 elendil:haesbaert: type ulimit
 ulimit is a shell builtin

the /etc/login.conf default values need to be fixed. this will reduce
the number of emails asking the same question in so many different
forms.



Re: Giving java apps more memory

2011-11-21 Thread Alexander Hall

On 11/19/11 05:27, John Tate wrote:


There is no manpage for ulimit.


It's in ksh(1) (and I'd suspect in other shell's man pages too)



Re: Giving java apps more memory

2011-11-18 Thread Richard Toohey
On 19/11/2011, at 4:12 PM, John Tate wrote:

 Netbeans crashes with this...

 john@rothbard ~$ netbeans
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 32784 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=17843, tid=8647815168
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid17843.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #
 Abort trap (core dumped)

 Eclipse crashes with this...
 [john@rothbard ~$ eclipse
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 1565456 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=30120, tid=8844312576
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid30120.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #

 How should I proceed?


OpenBSD / this list appreciate people who do a bit of homework.

What did you find in Google?

What research have you done?

What have you tried?

Just mailing this list with every problem you have is going to wear people
out.

 --
 www.johntate.org



Re: Giving java apps more memory

2011-11-18 Thread Andres Perera
you can patch the apps to use setrlimit()

you can write a small sh wrapper that sets ulimits and execs your app

you can also set your defaults in /etc/login.conf or ~/.profile

depends on what you want

i use gimp and ff so login.conf/.profile is really more sensible than
wrapping all the monster apps

On Fri, Nov 18, 2011 at 10:42 PM, John Tate j...@johntate.org wrote:
 Netbeans crashes with this...

 john@rothbard ~$ netbeans
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 32784 bytes for Chunk::new.
 Out of swap space?
 #
 # B Internal Error (allocation.cpp:272), pid=17843, tid=8647815168
 # B Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid17843.log
 #
 # If you would like to submit a bug report, please visit:
 # B  http://java.sun.com/webapps/bugreport/crash.jsp
 #
 Abort trap (core dumped)

 Eclipse crashes with this...
 [john@rothbard ~$ eclipse
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 1565456 bytes for Chunk::new.
 Out of swap space?
 #
 # B Internal Error (allocation.cpp:272), pid=30120, tid=8844312576
 # B Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid30120.log
 #
 # If you would like to submit a bug report, please visit:
 # B  http://java.sun.com/webapps/bugreport/crash.jsp
 #

 How should I proceed?


 --
 www.johntate.org



Re: Giving java apps more memory

2011-11-18 Thread John Tate
[john@rothbard ~$ ulimit
unlimited

There is something very simple I am missing.

I'm getting really confused here.

On Sat, Nov 19, 2011 at 2:53 PM, Andres Perera andre...@zoho.com wrote:
 you can patch the apps to use setrlimit()

 you can write a small sh wrapper that sets ulimits and execs your app

 you can also set your defaults in /etc/login.conf or ~/.profile

 depends on what you want

 i use gimp and ff so login.conf/.profile is really more sensible than
 wrapping all the monster apps

 On Fri, Nov 18, 2011 at 10:42 PM, John Tate j...@johntate.org wrote:
 Netbeans crashes with this...

 john@rothbard ~$ netbeans
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 32784 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=17843, tid=8647815168
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid17843.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #
 Abort trap (core dumped)

 Eclipse crashes with this...
 [john@rothbard ~$ eclipse
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 1565456 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=30120, tid=8844312576
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid30120.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #

 How should I proceed?


 --
 www.johntate.org






--
www.johntate.org



Re: Giving java apps more memory

2011-11-18 Thread John Tate
Is this information helpful...

john@rothbard ~$ ulimit -a
core file size  (blocks, -c) unlimited
data seg size   (kbytes, -d) 524288
file size   (blocks, -f) unlimited
max locked memory   (kbytes, -l) 1354329
max memory size (kbytes, -m) 4059940
open files  (-n) 128
pipe size(512 bytes, -p) 1
stack size  (kbytes, -s) 4096
cpu time   (seconds, -t) unlimited
max user processes  (-u) 128
virtual memory  (kbytes, -v) 528384

I need to change this one in login.conf or in my .profile...
max memory size (kbytes, -m) 4059940

There is no manpage for ulimit.


On Sat, Nov 19, 2011 at 2:12 PM, John Tate j...@johntate.org wrote:
 Netbeans crashes with this...

 john@rothbard ~$ netbeans
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 32784 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=17843, tid=8647815168
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid17843.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #
 Abort trap (core dumped)

 Eclipse crashes with this...
 [john@rothbard ~$ eclipse
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 1565456 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=30120, tid=8844312576
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid30120.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #

 How should I proceed?


 --
 www.johntate.org




--
www.johntate.org



Re: Giving java apps more memory

2011-11-18 Thread John Tate
Found it in the info page. I'm going to STFU and come back tomorrow if
I'm still this stupid.

On Sat, Nov 19, 2011 at 3:27 PM, John Tate j...@johntate.org wrote:
 Is this information helpful...

 john@rothbard ~$ ulimit -a
 core file size  (blocks, -c) unlimited
 data seg size   (kbytes, -d) 524288
 file size   (blocks, -f) unlimited
 max locked memory   (kbytes, -l) 1354329
 max memory size (kbytes, -m) 4059940
 open files  (-n) 128
 pipe size(512 bytes, -p) 1
 stack size  (kbytes, -s) 4096
 cpu time   (seconds, -t) unlimited
 max user processes  (-u) 128
 virtual memory  (kbytes, -v) 528384

 I need to change this one in login.conf or in my .profile...
 max memory size (kbytes, -m) 4059940

 There is no manpage for ulimit.


 On Sat, Nov 19, 2011 at 2:12 PM, John Tate j...@johntate.org wrote:
 Netbeans crashes with this...

 john@rothbard ~$ netbeans
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 32784 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=17843, tid=8647815168
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid17843.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #
 Abort trap (core dumped)

 Eclipse crashes with this...
 [john@rothbard ~$ eclipse
 #
 # A fatal error has been detected by the Java Runtime Environment:
 #
 # java.lang.OutOfMemoryError: requested 1565456 bytes for Chunk::new.
 Out of swap space?
 #
 #  Internal Error (allocation.cpp:272), pid=30120, tid=8844312576
 #  Error: Chunk::new
 #
 # JRE version: 7.0
 # Java VM: OpenJDK 64-Bit Server VM (20.0-b03 mixed mode bsd-amd64
 compressed oops)
 # An error report file with more information is saved as:
 # /home/john/hs_err_pid30120.log
 #
 # If you would like to submit a bug report, please visit:
 #   http://java.sun.com/webapps/bugreport/crash.jsp
 #

 How should I proceed?


 --
 www.johntate.org




 --
 www.johntate.org




--
www.johntate.org