AIX Study-AIX user resource access restriction configuration, aix-aix

Source: Internet
Author: User

AIX Study-AIX user resource access restriction configuration, aix-aix

AIX Study-AIX user access system resource limit Configuration

The system resource limits used by Aix users include hard limits and soft limits ). Hard limits has been introduced since Aix 4.1. Hard limits should be set by the Aix system administrator. Only members in the security Group can increase the value. Users can reduce the value but the change will expire as the user exits from the system.

Use the following command to view the limits of hard limits: ulimit-Hasoft limits is the upper limit of the system resources used by the Aix core. This value can be changed by anyone, but cannot exceed the hard limits value. Note that only the members of the security Group can make the changes take effect permanently. changes made by common Aix users will expire after they exit the system.

Run the following command to view the soft limits settings: ulimit-
The default values of soft limits are as follows:
 

 
 
  1. 3.2  
  2. 4.1-4.3 
  3. ===============  
  4. =================  
  5. fsize = 2097151 
  6. fsize = 2097151 
  7. core = 2048 
  8. core = 2048 
  9. cpu = 3600 
  10. cpu = -1  
  11. data = 131072 
  12. data = 262144 
  13. rss = 65536 
  14. rss = 65536 
  15. stack = 8192 
  16. stack = 65536 
  17. nofiles = 2000*   
  18. nofiles=2000 * 

* This value (nofiles) can only be changed in Aix 4.3.1 or later versions.

The above definition is stored in the file/etc/security/limits as the default value, and takes effect after new users are added to the system. To directly change the definition value in this file, you need to restart the system for the change to take effect. "-1" indicates that the value is not limited by soft limits (unlimited ).

Next we will introduce each field one by one:
Fsize: the size limit of the file created by the user. This defined value (512 bytes in units) is the maximum size of files that can be generated by the user.
The size limit of the core file generated by the core (512 bytes ).
Cpu user process cpu limit (in seconds ). Normal users can only reduce this value, and root can increase this value. Note that the CPU usage time of a process depends on the Aix Kernel (core program) process scheduling algorithm. This value is for reference only.
Data Process data segment size limit (in bytes ).
Stack process stack segment size limit (in bytes ).
The limit of the resident memory segment of the rss process (in bytes ). The Aix core does not refer to this limitation.
The maximum number of files opened in nofiles. This limit is fixed in versions earlier than Aix 4.3.1 as 2000. This value can be increased to 32767 in Aix 4.3.1 and later versions.

In Aix users, the following three methods are used to modify the above limit:
1. edit the file/etc/security/limits and directly modify the defined values. This change takes effect after the system is restarted.

2. Run the command ulimit to modify the default value. For example:

 
 
  1. ulimit -f value  
  2. ulimit -c <value> 
  3. ulimit -t <value> 
  4. ulimit -d <value> 
  5. ulimit -s <value> 
  6. ulimit -m <value> 
  7. ulimit -n <value> 


The soft limit values of fsize, core, cpu, data, stack, rss, and nofiles will be modified.

3. Run the command chuser to modify the limit value of a user. For example:

 
 
  1. chuser fsize=<value> <username> 
  2. chuser core=<value> <username 
  3. chuser cpu=<value> <username> 
  4. chuser data=<value> <username> 
  5. chuser limit=<value> <username> 
  6. chuser rss=<value> <username> 
  7. chuser nofiles=<value> <username> 

Change the soft limits of user "username" to "value ".

 
 
  1. chuser hard_fsize=<value> <username> 
  2. chuser hard_core=<value> <username> 
  3. chuser hard_cpu=<value> <username> 
  4. chuser hard_data=<value> <username> 
  5. chuser hard_limit=<value> <username> 
  6. chuser hard_rss=<value> <username> 
  7. chuser hard_nofiles=<value> <username>

Change the hard limits of user "username" to "value ".

You can use the smit tool to modify:


After modification, the configuration information will be written/Etc/security/limits

[Root @ aix211/] # cat/etc/security/limits

oracle:        fsize = -1        data = -1        stack = -1        core = -1



Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.