In
computing, a system resource, or simple resource, is any
physical or
virtual component of limited availability within a
computer system. All connected devices and internal system components are resources. Virtual system resources include
files
File or filing may refer to:
Mechanical tools and processes
* File (tool), a tool used to ''remove'' fine amounts of material from a workpiece
**Filing (metalworking), a material removal process in manufacturing
** Nail file, a tool used to gent ...
(concretely
file handles),
network connections (concretely
network sockets), and
memory areas.
Managing resources is referred to as
resource management, and includes both preventing
resource leak
In computer science, a resource leak is a particular type of resource consumption by a computer program where the program does not release resources it has acquired. This condition is normally the result of a bug in a program. Typical resource lea ...
s (not releasing a resource when a process has finished using it) and dealing with
resource contention (when multiple processes wish to access a limited resource). Computing resources are used in
cloud computing to provide services through networks.
Major resource types
*
Interrupt request (IRQ) lines
*
Direct memory access (DMA) channels
*
Port-mapped I/O
*
Memory-mapped I/O
*
Locks
* External
devices
* External memory or objects, such as memory managed in native code, from Java; or objects in the
Document Object Model (DOM), from
JavaScript
General resources
*
CPU
A central processing unit (CPU), also called a central processor, main processor or just processor, is the electronic circuitry that executes instructions comprising a computer program. The CPU performs basic arithmetic, logic, controlling, and ...
, both time on a single CPU and use of multiple CPUs – see
multitasking
*
Random-access memory and
virtual memory – see
memory management
*
Hard disk
A hard disk drive (HDD), hard disk, hard drive, or fixed disk is an electro-mechanical data storage device that stores and retrieves digital data using magnetic storage with one or more rigid rapidly rotating platters coated with magnet ...
drives, include space generally, contiguous free space (such as for swap space), and use of multiple physical devices ("spindles"), since using multiple devices allows parallelism
* Cache space, including
CPU cache and MMU cache (
translation lookaside buffer)
*
Network throughput
*
Electrical power
*
Input/output operations
*
Randomness
Categories
Some resources, notably memory and storage space, have a notion of "location", and one can distinguish ''contiguous'' allocations from ''non-contiguous'' allocations. For example, allocating 1 GB of memory in a single block, versus allocating it in 1,024 blocks each of size 1 MB. The latter is known as
fragmentation
Fragmentation or fragmented may refer to:
Computers
* Fragmentation (computing), a phenomenon of computer storage
* File system fragmentation, the tendency of a file system to lay out the contents of files non-continuously
* Fragmented distributi ...
, and often severely impacts performance, so ''contiguous'' free space is a subcategory of the general resource of storage space.
One can also distinguish ''compressible'' resources from ''incompressible'' resources.
The Kubernetes resource model
"Some resources, such as CPU and network bandwidth, are compressible, meaning that their usage can potentially be throttled in a relatively benign manner." Compressible resources, generally throughput ones such as CPU and network bandwidth, can be throttled benignly: the user will be slowed proportionally to the throttling, but will otherwise proceed normally. Other resources, generally storage ones such as memory, cannot be throttled without either causing failure (if a process cannot allocate enough memory, it typically cannot run) or severe performance degradation, such as due to thrashing (if a working set does not fit into memory and requires frequent paging, progress will slow significantly). The distinction is not always sharp; as mentioned, a paging system can allow main memory (primary storage) to be compressed (by paging to hard drive (secondary storage)), and some systems allow discardable memory for caches, which is compressible without disastrous performance impact. Electrical power is to some degree compressible: without power (or without sufficient voltage) an electrical device cannot run, and will stop or crash, but some devices, notably mobile phones, can allow degraded operation at reduced power consumption, or can allow the device to be suspended but not terminated, with much lower power consumption.
See also
* Computational resource
* Linear scheduling method
* Sequence step algorithm
* System monitor
References
{{reflist
Resources
Computing terminology