User Classes Each OpenBSD user has a login
Some variables, of course, require particular sorts of values. A path to the home directory must be a full path, while the amount of memory the user may use cannot be a full path. In most cases, the legitimate answers are fairly obvious. Note On many BSD systems, you must use cap_mkdb(8) to build a database file containing the values in /etc/login.conf for the changes to take effect. This is not necessary in OpenBSD; programs can parse /etc/login.conf directly. If you run cap_mkdb(8) on /etc/login.conf once, however, you must either continue to use it thereafter or remove the database file. OpenBSD’s default /etc/login.conf contains a few different classes of users. If you want an idea of what sort of restrictions to put on users for various situations, check that file. Here, we’re just going to discuss some of the commonly changed items. Resource Limits Resource limits allow you to control how much of the system any one user can tie up at one time. If you have several hundred users logged in to one machine, and one of those users decides to compile 30MB of source code, that person can consume far more than his fair share of processor time and memory. By limiting the resources that one user can monopolize at one time, you can make the system more responsive for less needy users. You can also give different login classes different resource limits. Resource limits are frequently tied to each process. If you allow each process to use up to 20MB of RAM, and you allow each user to start 20 processes, one user could theoretically consume up to 400MB of memory. Here are several popular resource-limiting login.conf variables. coredumpsize The maximum size of any core dump cputime The maximum CPU time any process may use datasize The maximum memory size of data that can be consumed by one process filesize The maximum size of any file stacksize The maximum amount of memory on the stack usable by a process memoryuse The maximum amount of memory a process can lock maxproc The maximum number of processes the user can have running openfiles The maximum number of open files per process Current and Maximum Resource Limits The login.conf mechanism supports both advisory (or current) and maximum resource limits. Current limits (-cur) are generally advisory, and the user can override them at will. This works well on a cooperative system, where multiple users willingly share resources. Maximum limits (-max) are absolutes, and the user cannot exceed them. To specify a current limit, add -cur to the limit name. To make a hard limit, add -max. For example, to limit the number of processes a user can have to 60, but give them a warning when they’ve used up half the maximum, you could do this: :maxproc-cur=30: :maxproc-max=60: If you don’t specify either -cur or -max, limits are hard limits and cannot be exceeded by the user. Default Environment Setting Page 140
Note: If you are looking for cheap and quality provider to host and run your java application check Astra java hosting services