1844052 Members
2676 Online
110227 Solutions
New Discussion

Re: Process Size limit

 
SOLVED
Go to solution
Dhirendra Singh
Occasional Advisor

Process Size limit

I want to know what is the process size limit in 64bit mode.
My OS is
hpitan2 spdwrk3 spdwrk3 > uname -a
HP-UX hpitan2 B.11.23 U ia64 3411090122 unlimited-user license

also is there any tool available on HP-UX is can analyze the process memory...like what is the size of the process heap, stack, shared memory segment etc...
9 REPLIES 9
Dennis Handly
Acclaimed Contributor
Solution

Re: Process Size limit

maxdsiz_64bit and the amount of swap space you have.
Dhirendra Singh
Occasional Advisor

Re: Process Size limit

As i understand maxdsiz_64bit is for maximum size of data(heap) segment.
is the maximum size of a process is limited by the maximum size of its data segement ?

value of maxdsize_64bit on my system is
maxdsiz_64bit 4294967296 Default Immed

Steven E. Protter
Exalted Contributor

Re: Process Size limit

Shalom,

Glance is the best tool for analyzing process characteristics. It is not free but its on your application and core OS cd in a 60 day trial format. Once you like it, you can get a permanent license.

If your process uses shared memory then its size is normally limited by shmmax kernel parameter. kmtune or kctune to see current settings. Or SAM

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
Dennis Handly
Acclaimed Contributor

Re: Process Size limit

>As i understand maxdsiz_64bit is for maximum size of data(heap) segment.

Yes.

>is the maximum size of a process is limited by the maximum size of its data segment?

Realistically, there is a separate one for stack and text but those should be trivial in size. And probably one for shared memory.

>value of maxdsize_64bit on my system is 4 Gb.

The hardware supports up to 2^48 or so. So really the limit is swap space.
Dhirendra Singh
Occasional Advisor

Re: Process Size limit

How i can know what is the size of the swap space ?
A. Clay Stephenson
Acclaimed Contributor

Re: Process Size limit

swapinfo -tam
If it ain't broke, I can fix that.
Dennis Handly
Acclaimed Contributor

Re: Process Size limit

>How i can know what is the size of the swap space?

The reason I mention swap space is that you could want your process maxdsiz_64 bit to be 1 Tb but your RAM maybe in terms of Gb.
Dhirendra Singh
Occasional Advisor

Re: Process Size limit

So you mean to say that there is no OS limit for process size. it can only be limited by the values of maxdsiz_64bit,maxssiz_64bit,maxtsiz_64bit and swap space.

ulimit command prints different value for data and stack sizes.
Which one will take precedence for a process ?
value shown by ulimit or kctune ?
Bill Hassell
Honored Contributor

Re: Process Size limit

> So you mean to say that there is no OS limit for process size.

No, there is a limit, but it is measured in thousands of gigabytes.

> it can only be limited by the values of maxdsiz_64bit,maxssiz_64bit,maxtsiz_64bit and swap space.

The kernel parameters are simply fences or limits that the sysadmin want to place on processes in case one grabs all RAM and all swap space -- much to the detriment of all other users. If you set maxdsiz_64 to 900 GB and you only have 50 GB of swap space, then your process will be limited to 50 GB of local memory. Because HP-UX is a virtual memory system, RAM is just a special case of all the addressing space available. If you want a process to use 900 GB of memory, you'll need to provide slightly more than 900 GB of swap space.

NOTE: be prepared for enormous delays (minutes to hours) running programs that require dozens of GB of RAM. These programs will be paused most of the time while memory is rearranged and pages are swapped in and out of memory. While the 64bit limits are extremely large, it does not mean that it is a good idea to use 100 times more RAM than you have available. And note that such swapping affects *every* process in the system because memory is being rearranged. The system overhead is enormous. If you need to run a process using 100 GB of memory, make sure you upgrade your computer to 128 GB of RAM.

> ulimit command prints different value for data and stack sizes. Which one will take precedence for a process? value shown by ulimit or kctune ?

When ulimit says unlimited, it means that maxdsiz_64 is the limit. If ulimit reports a value, than that is the limit in the current environment. ulimit is a shell built-in that can report or modify the current environment.


Bill Hassell, sysadmin