How to set systemwide ulimit on ubuntu
Solution 1:
You can set these in /etc/security/limits.conf on Red Hat systems. I think it's the same on Ubuntu. It has examples by default, they're pretty straightforward. Post back if you have problems.
In /etc/security/limits.conf add:
root - core unlimited
* - core unlimited
You will need to log out and log back in before the limits are applied to your session.