Opennebula VM ulimit changes

Hi All,

I’m using opennebula4.14.2. My opennebula front-end server’s ulimit is

$ulimit -n
65535

My vm’s ulimit is 1024.
I want to change the vm’s ulimit to 65535.
How can i do that?

This is nothing to do with OpenNebula, it is about Linux. You can set/change the limit permanently by editing /etc/limits.conf or /etc/security/limits.conf

Example:

#<domain>    <type>    <item>    <value>
*            soft      nofile    65535
*            hard      nofile    65535
1 Like

Hi @anandharaj,

Thanks for your response.

I set the limit in /etc/security/limits.conf as you said, and restarted the vm.

But, ulimit is still 1024. What shall i do to set vm’s ulimit?

My VM is having Ubuntu14.04.

@thomasalrin,

You run “ulimit” as what user? Could you post the output of “ulimit -S -a” and “ulimit -H -a”

Hi @anandharaj,

I run ‘ulimit’ as ‘root’ user.

$ ulimit -S -a

core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
scheduling priority (-e) 0
file size (blocks, -f) unlimited
pending signals (-i) 7775
max locked memory (kbytes, -l) 64
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) 819200
real-time priority (-r) 0
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) 7775
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited

$ ulimit -H -a

core file size (blocks, -c) unlimited
data seg size (kbytes, -d) unlimited
scheduling priority (-e) 0
file size (blocks, -f) unlimited
pending signals (-i) 7775
max locked memory (kbytes, -l) 64
max memory size (kbytes, -m) unlimited
open files (-n) 4096
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) 819200
real-time priority (-r) 0
stack size (kbytes, -s) unlimited
cpu time (seconds, -t) unlimited
max user processes (-u) 7775
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited

@thomasalrin

Okay, the domain " * " is not applicable to root, therefore try replace it with “root”

#<domain>    <type>    <item>    <value>
root         soft      nofile    65535
root         hard      nofile    65535
1 Like

Hi @anandharaj ,

Super, this is working cool.

Thank you @anandharaj :smile: