Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 02-10-2005, 10:04 AM   #1
LQ Newbie
Registered: Feb 2005
Posts: 1

Rep: Reputation: 0
Unhappy ulimit settings in /etc/profile

I'm running Red Hat 2.4.7-10enterprise and I have replaced the standard ulimit -c setting with the following statement in /etc/profile:

$ grep ulimit /etc/profile
#ulimit -S -c 0 > /dev/null 2>&1
ulimit -c unlimited

However when I log and check the ulimit value I see it set to 4194304:

$ ulimit -a
time(seconds) 2147483647
file(blocks) 4194304
data(kbytes) 2097152
stack(kbytes) 8192
memory(kbytes) 2097152
coredump(blocks) 4194304
nofiles(descriptors) 1024
vmemory(kbytes) 2097152

my default shell is set to /bin/ksh:
$ ps
10644 pts/12 00:00:00 ksh
11280 pts/12 00:00:00 ps

Why isn't the new ulimit setting being picked up? Isn't /etc/profile read when ksh is used?
Old 02-10-2005, 11:11 AM   #2
LQ Guru
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Wheezy, Debian Jessie
Posts: 7,661

Rep: Reputation: 229Reputation: 229Reputation: 229
"Why isn't the new ulimit setting being picked up? "

The new ulimit has been picked up. The coredump has changed from 0 to 4194304 which I suppose is the number that ulimit uses to mean unlimited. On the version of ulimit that I use it prints "unlimited" instead of the number.

core file size (blocks, -c) unlimited
data seg size (kbytes, -d) unlimited
file size (blocks, -f) unlimited
max locked memory (kbytes, -l) unlimited
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
stack size (kbytes, -s) unlimited
cpu time (seconds, -t) unlimited
max user processes (-u) 3968
virtual memory (kbytes, -v) unlimited

"Isn't /etc/profile read when ksh is used?"

The ulimit command is actually part of the shell. That is why your ksh formats the output from the ulimit command differently than my bash does.

Steve Stites

Last edited by jailbait; 02-10-2005 at 11:15 AM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
ulimit Serena Linux - Software 6 12-17-2014 11:04 PM
ulimit changes and /etc/profile rmount Linux - Software 3 11-02-2005 06:43 AM
ulimit -t juanbobo Linux - Security 3 06-10-2005 09:43 AM
switch profile/ settings in different locations raynet Linux - Wireless Networking 5 02-02-2005 11:54 AM
ulimit -n evilrico Linux - Distributions 0 03-14-2003 04:23 PM

All times are GMT -5. The time now is 02:53 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration