Operating System - HP-UX
1855769 Members
1746 Online
104103 Solutions
New Discussion

Cannot raise "ulimit -d": not owner

 
Lenz Grimmer
New Member

Cannot raise "ulimit -d": not owner

Hi, I am running out of ideas with this one. I am trying to resolve the following compile problem:

Malloc is out of memory, leaks over 512k:
/usr/ccs/bin/ld: Out of memory
Malloc: 98171872 bytes allocated by Unknown:0x3a0b7
Malloc: 1064960 bytes allocated by Unknown:0x38083

I assume I would need to increase the data segment size (ulimit -d), as it's currently set as follows:

data seg size (kbytes) 180224

However, I can not change the value to any other number, I always get "bash: ulimit: cannot modify limit: Not owner". There is no /etc/profile or any other dot file in $HOME that is messing with the ulimits. I already reconfigured the kernel to the following value (from /stand/system):

maxdsiz 0X0B000000

How come that this value is not propagated to my user account? Any suggestions would be appreciated. Thanks in advance!
8 REPLIES 8
Deoncia Grayson_1
Honored Contributor

Re: Cannot raise "ulimit -d": not owner

Steven E. Protter
Exalted Contributor

Re: Cannot raise "ulimit -d": not owner

Can you post ulimit -a output from the user?

This issue may not be what we think.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Sanjay_6
Honored Contributor

Re: Cannot raise "ulimit -d": not owner

Stuart Abramson
Trusted Contributor

Re: Cannot raise "ulimit -d": not owner

A. ulimit sets limits.

B. To see you limits:

# ulimit -a
time(seconds) unlimited
file(blocks) unlimited
data(kbytes) 244140
stack(kbytes) 12288
memory(kbytes) unlimited
coredump(blocks) 4194303

C. To set your own limits:

ulimit -d 100000 Where 100000 is < 244140

D. To Fix "oracle" ID limits:

1. Log in as root.

2. Use ulimit() to check settings:

# ulimit -a

3. Reset ulimit() to its maximum value:

# ulimit -d 65536 oracle

4. Have the Oracle user log off and back on.

E. NOTE: See the manual page for sh-posix(1) for information
about ulimit().

F. The .proto file sets up the ulimit.

I don't understand how it works.

cat /var/adm/cron/.proto

# @(#) $Revision: 27.1 $
cd $d
ulimit $l
umask $m
$<

Lenz Grimmer
New Member

Re: Cannot raise "ulimit -d": not owner

Thanks for all your replies, here is some more info. By the way, this system is a hp3750, running HP-UX 11.00.

The full output of "ulimit -Sa" for this user:

core file size (blocks) 2097151
data seg size (kbytes) 180224
file size (blocks) unlimited
max memory size (kbytes) unlimited
open files 4096
pipe size (512 bytes) 16
stack size (kbytes) 70656
cpu time (seconds) unlimited
max user processes 201
virtual memory (kbytes) unlimited

"ulimit -Ha" reports:

core file size (blocks) unlimited
data seg size (kbytes) 180224
file size (blocks) unlimited
max memory size (kbytes) unlimited
open files 4096
pipe size (512 bytes) 16
stack size (kbytes) 70656
cpu time (seconds) unlimited
max user processes 201
virtual memory (kbytes) unlimited

I will take a look at the other suggestions made in this thread.

Lenz Grimmer
New Member

Re: Cannot raise "ulimit -d": not owner

And some more info:

Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 1024 0 1024 0% 0 - 1 /dev/vg00/lvol2
dev 2048 0 2048 0% 0 - 0 /dev/vg00/swap
reserve - 98 -98
memory 1535 1057 478 69%
total 4607 1155 3452 25% - 0 -
bash-2.05$ grep -i maxssiz /stand/system
maxssiz 0X04500000
Lenz Grimmer
New Member

Re: Cannot raise "ulimit -d": not owner

OK, sometimes it helps doing the math first...
My apologies for wasting your time on something as trivial as this...

"ulimit -d" reports 180224 kbytes. The value "maxdsiz" was set to "0X0B000000" (in bytes), which are exactly 180224 kbytes...

Duh!

Raising the maxdsiz value a bit more (now to "0X20000000") also affects the ulimit:

data seg size (kbytes) 524288

Consider this case closed - this was a pilot error :)
Lenz Grimmer
New Member

Re: Cannot raise "ulimit -d": not owner

See my last comment - a typical case of PEBKAC...