- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- How to limit a special user's process can not use ...
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
Forums
Discussions
Discussions
Discussions
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
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
04-27-2006 02:53 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2006 03:10 AM
04-27-2006 03:10 AM
Re: How to limit a special user's process can not use too many memory?
2) Not as powerful but will work. Add a ulimit -d nnnn command either to his .profile or create a wrapper script for the program that does a limit -d before exec'ing the program.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2006 03:11 AM
04-27-2006 03:11 AM
Re: How to limit a special user's process can not use too many memory?
There are various limits
data segment, stack, memory - which you can see by ulimit -a
In the user's .profile insert the following line
ulimit -d data_size_kb
ulimit -s stack_size_kb
ulimit -m memory_size_kb
Put the necessary value in KB
Hope that helps,
Ninad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-27-2006 11:41 PM
04-27-2006 11:41 PM
Re: How to limit a special user's process can not use too many memory?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2006 02:21 AM
04-28-2006 02:21 AM
SolutionAgain, you could create a wrapper that would invoke the "real" program after setting ulimit to some desired value and moving the "real" program somewhere else. If that wrpapper is a script then because the user must have read permission to execute it, he can easily see where the real program is. It would be better in this case to create a C wrapper and only set the execute bits so that it would not be vulnerable to a strings command.
Fundamentally, I think you are taking the wrong approach. You should discuss the problem with this user. If this is an application for which you have the source code then the limits could be a command-line option; if this is a memory leak problem then it should be fixed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-28-2006 04:56 AM
04-28-2006 04:56 AM
Re: How to limit a special user's process can not use too many memory?
As Clay mentioned, this is a social engineering problem more than a technical problem. If the user insists on running a program that occupies far too much RAM (and requests to stop are ignored) then simply ask this person's manager to buy a very large amount of RAM just for this one person. That usually solves the problem.
Bill Hassell, sysadmin