Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 6776
  • Last Modified:

Permanently Set ulimit on Linux (Ubuntu 7)

I am using Linux (Ubuntu 7.04)

I want to turn on core-dumping so I can debug programs that crash.  This is a simple matter of typing ulimit -c followed by the allowable size of the core dump.

However, this only sets ulimit temporarily.  As soon as I Iog off and then back on, ulimit is set back to 0.  How can I permanently set ulimit?

I tried placing the line ulimit -c 50000 into various files, such as bash.bashrc, /etc/rc.local, and /etc/init.d/rc.local, but all of this has no effect.  ulimit -c is always back to 0 when I log off/log on.

0
chsalvia
Asked:
chsalvia
  • 2
1 Solution
 
Kent OlsenData Warehouse Architect / DBACommented:
Hi chsalvia,

I almost hate to ask, but did you try putting it in the  .profile?


Good Luck,
Kent
0
 
ravenplCommented:
if ubuntu uses PAM
/etc/security/limits.conf
0
 
chsalviaAuthor Commented:
I forgot to try /etc/profile.  Thanks, that worked.
0
 
ravenplCommented:
Really /etc/security/limits.conf is much better for such job...
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now