sysbench Cannot allocate memory
时间:2007-01-08 来源:gladness
sysbench --test=threads --num-threads=1500 run
sysbench v0.4.8: multi-threaded system evaluation benchmark
Running the test with following options:
Number of threads: 1500
Doing thread subsystem performance test
Thread yields per test: 1000 Locks used: 8
FATAL: Thread #305 creation failed errno = 12 (Cannot allocate memory)
ulimit -a
core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
max locked memory (kbytes, -l) 4
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
stack size (kbytes, -s) 10240
cpu time (seconds, -t) unlimited
max user processes (-u) 7168
virtual memory (kbytes, -v) unlimited
ulimit -s 1024
sysbench --test=threads --num-threads=1500 run
sysbench v0.4.8: multi-threaded system evaluation benchmark
Running the test with following options:
Number of threads: 1500
Doing thread subsystem performance test
Thread yields per test: 1000 Locks used: 8
Threads started!
用ulimit -s把stack size改小,就可以创建更多的线程而不导致内存不够。
sysbench v0.4.8: multi-threaded system evaluation benchmark
Running the test with following options:
Number of threads: 1500
Doing thread subsystem performance test
Thread yields per test: 1000 Locks used: 8
FATAL: Thread #305 creation failed errno = 12 (Cannot allocate memory)
ulimit -a
core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
max locked memory (kbytes, -l) 4
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
stack size (kbytes, -s) 10240
cpu time (seconds, -t) unlimited
max user processes (-u) 7168
virtual memory (kbytes, -v) unlimited
ulimit -s 1024
sysbench --test=threads --num-threads=1500 run
sysbench v0.4.8: multi-threaded system evaluation benchmark
Running the test with following options:
Number of threads: 1500
Doing thread subsystem performance test
Thread yields per test: 1000 Locks used: 8
Threads started!
用ulimit -s把stack size改小,就可以创建更多的线程而不导致内存不够。
相关阅读 更多 +