In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly introduces how solaris10 uses projadd to add resource restrictions, which has a certain reference value, interested friends can refer to, I hope you can learn a lot after reading this article, the following let the editor take you to understand.
When installing oracle, you need to configure resource restrictions:
Noexec_user_stack=1
Semsys:seminfo_semmni=100
Semsys:seminfo_semmns=1024
Semsys:seminfo_semmsl=256
Semsys:seminfo_semvmx=32767
Shmsys:shminfo_shmmax=4294967295
Shmsys:shminfo_shmmni=100
Rlim_fd_max=65536
Rlim_fd_cur=4096
Maxuprc=16384
Max_nprocs=3000
Use project (effective immediately, permanent)
Project is a new addition to Solaris10, and you can set parameter values for a user or group of users by setting the project parameter. It can take effect immediately after setting.
However, the results of root users are only affected by the parameters in / etc/system, not by project user.oracle. Root users do not belong to this project. '
The following is an example of the settings:
-- root execution
Bash-3.2#: / # > projadd user.oracle (create project user.oracle)
Bash-3.2#: / # > id-p oracle
Uid=100 (oracle) gid=1 (other) projid=100 (user.oracle) (oracle user belongs to project user.oracle)
Bash-3.2#: / # > projmod-a-K "process.max-file-descriptor= (basic,65534,deny)" user.oracle
Bash-3.2#: / # > projmod-a-K "process.max-file-descriptor= (priv,65535,deny)" user.oracle
Bash-3.2#: / # > grep 'user.oracle' / etc/project
User.oracle:100::::process.max-file-descriptor= (basic,65534,deny), (priv,65535,deny)
Set the basic and privilege values to 65534 and 65535 respectively, which cannot exceed the maximum hard limit of 65535 in / etc/system
Bash-3.2#: / # > tail-2 / etc/system
Set rlim_fd_cur=1024
Set rlim_fd_max=65535
Bash-3.2# plimit
13110: bash
Resource current maximum
Time (seconds) unlimited unlimited
File (blocks) unlimited unlimited
Data (kbytes) unlimited unlimited
Stack (kbytes) 10240 unlimited
Coredump (blocks) unlimited unlimited
Nofiles (descriptors) 256 65536
Vmemory (kbytes) unlimited unlimited
Bash-3.2#
The results of root users are only affected by the parameters in / etc/system, not by project user.oracle. Root users do not belong to this project.
Bash-3.2# su-oracle
Oracle Corporation SunOS 5.10 Generic Patch January 2005
-sh: TEMP=/tmp: is not an identifier
$bash
Bash-3.2$ plimit
13110: bash resource current maximum time (seconds) unlimited unlimited file (blocks) unlimited unlimited data (kbytes) unlimited unlimited stack (kbytes) 10240 unlimited coredump (blocks) unlimited unlimited nofiles (descriptors) 25665536 vmemory (kbytes) unlimited unlimited bash-3.2# root users' results are only affected by the parameters in / etc/system, but not by project user.oracle. Root users do not belong to this project. Bash-3.2# su-oracle Oracle Corporation SunOS 5.10 Generic Patch January 2005-sh: TEMP=/tmp: is not an identifier $bash bash-3.2$ plimit
14704: bash
Resource current maximum
Time (seconds) unlimited unlimited
File (blocks) unlimited unlimited
Data (kbytes) unlimited unlimited
Stack (kbytes) 10240 unlimited
Coredump (blocks) unlimited unlimited
Nofiles (descriptors) 65534 65535
Vmemory (kbytes) unlimited unlimited
Bash-3.2 $
-- similarly, other parameters need to be modified as above:
Noexec_user_stack=1
Semsys:seminfo_semmni=100
Semsys:seminfo_semmns=1024
Semsys:seminfo_semmsl=256
Semsys:seminfo_semvmx=32767
Shmsys:shminfo_shmmax=4294967295
Shmsys:shminfo_shmmni=100
Rlim_fd_max=65536
Rlim_fd_cur=4096
Maxuprc=16384
Max_nprocs=3000
Projmod-a-K "project.max-sem-ids= (priv,100,deny)" user.oracle
Projmod-a-K "process.max-sem-nsems= (priv,256,deny)" user.oracle
Projmod-a-K "project.max-shm-memory= (priv,4294967295,deny)" user.oracle
Projmod-a-K "project.max-shm-ids= (priv,100,deny)" user.oracle
-
Thank you for reading this article carefully. I hope the article "how solaris10 uses projadd to add resource restrictions" shared by the editor will be helpful to everyone. At the same time, I also hope that you will support and follow the industry information channel. More related knowledge is waiting for you to learn!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.