- Community Home
- >
- Servers and Operating Systems
- >
- Legacy
- >
- Operating System - Tru64 Unix
- >
- Re: resource limit (max memory) question
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-11-2006 01:47 AM
тАО12-11-2006 01:47 AM
looking at the ulimit -a output it contains the
max memory size (kbytes) 19016312
line. looking at it with a syscall tracer, it looks that this is the RSS resource being used here. If I want to increase it, the documentation states to use the setrlimit (2) call, but I can't seem to use it the suggesteed way. If I use it with a smaller value, the setrlimit call succeeds but when i use larger values, it seems that it doen't get used.
The rss values in vm seem allow 100% and the enforce flag is not set.
/sbin/sysconfig -q vm | grep rss
vm_rss_maxpercent = 100
anon_rss_enforce = 0
vm_rss_block_target = 404
vm_rss_wakeup_target = 404
I haven't found a value in the proc subsystem or the kernel config file.
many thanks in advance for any help
Pit
#include
#include
int main(int argc, char *argv[])
{
struct rlimit rl;
unsigned long data_val;
unsigned long max_rss;
unsigned long cur_rss;
int res;
res = getrlimit ( RLIMIT_RSS, &rl );
if (res == 0) {
printf("RSS %ld %ld \n", rl.rlim_cur, rl.rlim_max);
}else{
printf(" RSS getrlimit errno %d\n", errno);
}
max_rss = rl.rlim_max;
cur_rss = rl.rlim_cur;
res = getrlimit ( RLIMIT_DATA, &rl );
if (res == 0) {
printf("DATA %ld %ld \n", rl.rlim_cur, rl.rlim_max);
}else{
printf(" DATA getrlimit errno %d\n", errno);
}
data_val = rl.rlim_cur;
/*
rl.rlim_cur = cur_rss - 1000;
rl.rlim_max = cur_rss;
*/
rl.rlim_cur = data_val;
res = setrlimit ( RLIMIT_RSS, &rl );
if (res == 0) {
printf("set RSS %ld %ld \n", rl.rlim_cur, rl.rlim_max);
}else{
printf(" RSS setrlimit errno %d\n", errno);
}
res = getrlimit ( RLIMIT_RSS, &rl );
if (res == 0) {
printf("RSS %ld %ld \n", rl.rlim_cur, rl.rlim_max);
}else{
printf(" RSS getrlimit errno %d\n", errno);
}
}
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-11-2006 02:20 AM
тАО12-11-2006 02:20 AM
Re: resource limit (max memory) question
perhaps it's worthwhile to apply a bit background. some people asked me how to increase this value. I resonded via
ulimit -m unlimited
but they said the value wouldn't change. They claim that this parameter is the only difference when compared with another machine, and due to this must be the culprit for achieving less performance in memory intensive work. Even I didn't believe it in first place, I failed to increase this value resulting in the former message/question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-11-2006 04:41 AM
тАО12-11-2006 04:41 AM
SolutionThey can change it if they purchase more DRAM.
I would not be surprised a memory-intensize application runs better with more memory in the system.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-11-2006 06:28 AM
тАО12-11-2006 06:28 AM
Re: resource limit (max memory) question
many thanks for the answer. Being able to read sometimes seems advantageous :-(
one minor issue is how to calculate this number out of the vmstat -P output, especially if gh is in use.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО12-12-2006 01:06 AM
тАО12-12-2006 01:06 AM
Re: resource limit (max memory) question
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1080328
You need to provide details of the 2 systems and the quantified performance difference to get good help.