Skip to Content
For Enterprise
For Government
For Higher Ed
For Individuals
For Marketing
For Enterprise
For Government
For Higher Ed
For Individuals
For Marketing
Explore Skills
Cloud Computing
Microsoft Azure
Amazon Web Services (AWS)
Google Cloud
Cloud Migration
Cloud Deployment
Cloud Platforms
Data Engineering
Data Warehouse
SQL
Apache Spark
Microsoft SQL Server
MySQL
Kafka
Data Lake
Streaming & Messaging
NoSQL Databases
Relational Databases
Data Science
Pandas
R
MATLAB
SAS
D3
Power BI
Tableau
Statistics
Exploratory Data Analysis
Data Visualization
AI & ML
Generative AI
Machine Learning
Artificial Intelligence (AI)
Deep Learning
Reinforcement Learning
Natural Language Processing
TensorFlow
Scikit-Learn
Hyperparameter Tuning
MLOps
Programming Languages
Java
JavaScript
Spring
Python
Go
C#
C++
C
Swift
Rust
Functional Programming
Software Architecture
Object-Oriented
Distributed Systems
Domain-Driven Design
Architectural Patterns
IT/Ops
Kubernetes
Docker
GitHub
Terraform
Continuous Delivery
Continuous Integration
Database Administration
Computer Networking
Operating Systems
IT Certifications
Security
Network Security
Application Security
Incident Response
Zero Trust Model
Disaster Recovery
Penetration Testing / Ethical Hacking
Governance
Malware
Security Architecture
Security Engineering
Security Certifications
Design
Web Design
Graphic Design
Interaction Design
Film & Video
User Experience (UX)
Design Process
Design Tools
Business
Agile
Project Management
Product Management
Marketing
Human Resources
Finance
Team Management
Business Strategy
Digital Transformation
Organizational Leadership
Soft Skills
Professional Communication
Emotional Intelligence
Presentation Skills
Innovation
Critical Thinking
Public Speaking
Collaboration
Personal Productivity
Confidence / Motivation
Features
All features
Verifiable skills
AI Academy
Courses
Certifications
Interactive learning
Live events
Superstreams
Answers
Insights reporting
Radar Blog
Buy Courses
Plans
Sign In
Try Now
O'Reilly Platform
book
LINUX系統程式設計 第二版
by
Robert Love
December 2013
Intermediate to advanced
496 pages
8h 57m
Chinese
GoTop Information, Inc.
Content preview from
LINUX系統程式設計 第二版
進階的行程管理
|
219
所有的資源限度都具有兩個特殊值:
0
及無限大(
infinity
)。前者用於完全停用相對應
的資源。舉例來說,如果
RLIMIT_CORE
被設為
0
,則核心將不會建立
core
檔。反過來
說,後者會移除資源上的任何限度。核心係透過
RLIM_INFINITY
這個特殊值(它恰巧就
是
-1
;這可能會導致一些混亂,因為傳回值也是以
-1
來指出錯誤)來表示無限大。如
果
RLIMIT_CORE
是無限大,核心將可建立任何大小的
core
檔案。
函式
getrlimit()
會把特定資源(經由
resource
指定)上當前的硬性和軟性限度擺進
rlim
所指向的結構。執行成功時,此呼叫會傳回
0
。執行失敗時,此呼叫會傳回
-1
以及
把
errno
設定成適當的值。
相同地,函式
setrlimit()
會把與
resource
相關的硬性和軟性限度設定成
rlim
所指向的
值。執行成功時,此呼叫會傳回
0
,而且核心會更新所要求的資源限度。執行失敗時,
此呼叫會傳回
-1
以及把
errno
設定成適當的值。
有哪些限度?
Linux
當前提供了
16
種資源限度:
RLIMIT_AS
一個行程之位址空間的尺寸上限,以位元組為單位。試圖(經由
mmap()
及
brk()
之
類的呼叫)增加位址空間的大小,讓它逾越此限度,將導致失敗以及傳回
ENOMEM
。
如果行程的堆疊(會按需要自動成長)擴大時逾越此限度,核心會傳送
SIGSEGV
信號
給該行程。此限度通常為
RLIM_INFINITY
。
RLIMIT_CORE
core
檔案的尺寸上限,以位元組為單位
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial
You might also like
優雅的SciPy|Python科學研究的美學
Juan Nunez-Iglesias, Stéfan van der Walt, Harriet Dashnow
成為卓越程式設計師的38項必修法則
Pete Goodliffe
深入理解運算原理|從簡單的機器到無所不能的程式
Tom Stuart
C++语言导学(原书第2版)
本贾尼 斯特劳斯特鲁普
Publisher Resources
ISBN: 9789862769812