process
A program that is currently running, with its own memory and a numeric identifier.
In more detail
When you start a program the operating system creates a process for it, gives it a process ID and tracks the memory, files and network connections it holds. Running the same program twice gives two separate processes, and a process can start child processes to do work in parallel. The operating system shares the processors between all running processes.
Examples
Ansible's forks setting is the number of parallel worker processes the control node runs, one per host being worked on.In the twelve-factor app the process is the unit of scaling: processes are stateless, disposable, run in the foreground and are managed by the platform.ps -o pid,comm # list processes with their IDsA program is an executable file on disk; a process is one running instance of it. The kernel gives each process a PID, records its parent, schedules its threads and tracks resources such as memory and open file descriptors. Replacing the file on disk does not change a process that is already running; it keeps its loaded image until restarted.Each python3 command you run starts a new interpreter process.Memory forensics lists processes and their parents to find impossible parent-child pairs.Related terms
- forks — The setting for how many hosts Ansible works on at the same time, using that many parallel worker processes on the control node.
- process ID — The number the kernel gives each running process so it can be told apart from all the others.
- child process — A process started by another process, its parent, from which it inherits a copy of the environment and current directory.
- signal — A short notification the kernel delivers to a process, such as please stop or stop now.
- exit code — A number a process returns when it finishes: 0 means success, anything else means something went wrong.
- service health check — A regular automatic test, run by a load balancer, Auto Scaling group or container service, of whether a copy of a service can really handle requests.
- compute options — The main ways to run code in the cloud: virtual machines, containers and functions, each moving a different amount of work to the provider.
- stateless process — A process that keeps nothing it needs between requests in its own memory or disk, so it can be restarted or replaced at any moment.
- process type — A named kind of work an app does, such as web for requests, worker for queued jobs or clock for scheduled tasks.
- foreground process — A process that keeps running as the one its launcher started, instead of detaching into the background.
- init process — The first process started on a system or in a container, with process ID 1 and special duties.
- container — A running program that has been fenced off from the rest of the computer so it only sees its own files, network and processes.
- executable — A file the operating system can load and run as a program, such as a compiled binary or a script with execute permission.
- parent process — The process that started another process; every process except the first records its parent's PID.
- process state — What a process is doing at a moment: running, sleeping while it waits for something, stopped, or finished but not yet collected (zombie).
- thread — A path of execution inside a process that the operating system schedules on a processor; one process can have many.
- subprocess module — The standard library module for running other programs from Python and collecting their output and exit code.
- memory — The fast, temporary working space where running programs keep their data; it is emptied when the machine powers off.
- environment variable — A named setting such as PORT=8000 that a program reads from its surroundings when it starts.
- local cache — A cache kept inside one application process's own memory, such as a dictionary.
- fault isolation — Designing so a failure in one part cannot take down the others.
Taught in
- Performance, Forks And Best Practices — Ansible Configuration Management at Scale
- What A Shell Is, And What Bash Is — Bash Scripting & Command Line Automation
- Which Shell Am I In, And Getting Bash Five — Bash Scripting & Command Line Automation
- Standard Input, Output And Error — Bash Scripting & Command Line Automation
- Redirection: Truncate, Append, Both Streams — Bash Scripting & Command Line Automation
- Pipelines, tee And Process Substitution — Bash Scripting & Command Line Automation
- Shell Variables, The Environment And export — Bash Scripting & Command Line Automation
- Command Substitution And Subshells — Bash Scripting & Command Line Automation
- Exit Codes, And What Success Means — Bash Scripting & Command Line Automation
- trap, Cleanup And Temporary Files — Bash Scripting & Command Line Automation
- POSIX sh Versus Bash — Bash Scripting & Command Line Automation
- Processes, Jobs And Signals — Bash Scripting & Command Line Automation
- Scheduling, Monitoring And A Script That Reports — Bash Scripting & Command Line Automation
- Container Images The Exam Way — Certified Kubernetes Application Developer (CKAD) Exam Prep
- Probes And Health Checks — Certified Kubernetes Application Developer (CKAD) Exam Prep
- Debugging Applications In Kubernetes — Certified Kubernetes Application Developer (CKAD) Exam Prep
- Requests, Limits And Quotas — Certified Kubernetes Application Developer (CKAD) Exam Prep
- SecurityContexts And Capabilities — Certified Kubernetes Application Developer (CKAD) Exam Prep
- IAM as the Foundation — Cloud Infrastructure & Hyperscaler Architecture
- The Danger of Long-Lived Keys — Cloud Infrastructure & Hyperscaler Architecture
- Elastic Compute Cloud (EC2) — Cloud Infrastructure & Hyperscaler Architecture
- Containers on AWS (ECS and EKS) — Cloud Infrastructure & Hyperscaler Architecture
- Serverless Compute (Lambda) — Cloud Infrastructure & Hyperscaler Architecture
- Comparing Compute Options — Cloud Infrastructure & Hyperscaler Architecture
- Elastic Block Store (EBS) — Cloud Infrastructure & Hyperscaler Architecture
- Build, Release, Run And Processes — DevOps & Site Reliability Engineering
- Port Binding And Concurrency — DevOps & Site Reliability Engineering
- Disposability, Dev Prod Parity And Logs — DevOps & Site Reliability Engineering
- Admin Processes And The Open Source Update — DevOps & Site Reliability Engineering
- Why Containers: Bare Metal, Machines And Processes — Docker Architecture & Production Containers
- Namespaces And Cgroups: Isolation And Limits — Docker Architecture & Production Containers
- Run, Stop, Restart And Remove A Container — Docker Architecture & Production Containers
- Commands, Logs, Exec And Exit Codes — Docker Architecture & Production Containers
- Run The Spine Service And Publish Its Port — Docker Architecture & Production Containers
- RUN, SHELL And Efficient Layer Caching — Docker Architecture & Production Containers
- ARG, ENV, LABEL, EXPOSE And VOLUME — Docker Architecture & Production Containers
- CMD, ENTRYPOINT, USER And Process Signals — Docker Architecture & Production Containers
- Authenticate, Tag, Push And Pull From A Registry — Docker Architecture & Production Containers
- Minimal Bases, Non Root Users And Smaller Images — Docker Architecture & Production Containers
- Ephemeral Filesystems And Named Volumes — Docker Architecture & Production Containers
- Bridge Networks, DNS And Container Communication — Docker Architecture & Production Containers
- Port Publishing, Localhost And Network Troubleshooting — Docker Architecture & Production Containers
- Environment, Secret Files And Runtime Restrictions — Docker Architecture & Production Containers
- Health Checks, Dependencies And Reliable Startup — Docker Architecture & Production Containers
- Development Overrides, Hot Reloading And Debuggers — Docker Architecture & Production Containers
- Diagnose Crashes, Resource Limits And Unhealthy Containers — Docker Architecture & Production Containers
- Harden And Deliver The Complete Service Stack — Docker Architecture & Production Containers
- How Browsers Work: Navigation, DNS, TCP, TLS And Request Timing — Frontend Architecture & Web Platform
- Your First Program and go run — Concurrent Systems Programming with Go
- Pointers and Memory — Concurrent Systems Programming with Go
- Errors as Values — Concurrent Systems Programming with Go
- Panics and Recover — Concurrent Systems Programming with Go
- Goroutines and Concurrent Execution — Concurrent Systems Programming with Go
- Context Cancellation and Timeouts — Concurrent Systems Programming with Go
- Graceful Shutdown on SIGTERM — Concurrent Systems Programming with Go
- Handling Timeouts and Errors — Concurrent Systems Programming with Go
- From Docker To Desired State — Kubernetes: Production-Grade Container Orchestration
- Control Plane: etcd, API Server, Scheduler, Controllers — Kubernetes: Production-Grade Container Orchestration
- Troubleshooting: describe, Events And A First Smoke Test — Kubernetes: Production-Grade Container Orchestration
- Pods, Init Containers And Sidecars — Kubernetes: Production-Grade Container Orchestration
- Troubleshooting: Probes, Logs, exec And CrashLoopBackOff — Kubernetes: Production-Grade Container Orchestration
- Troubleshooting: ImagePullBackOff And Failed Rollouts — Kubernetes: Production-Grade Container Orchestration
- ConfigMaps, Secrets And Configuration Updates — Kubernetes: Production-Grade Container Orchestration
- securityContext: Nonroot, Capabilities And Seccomp — Kubernetes: Production-Grade Container Orchestration
- What A Kernel Does, And What It Refuses To Do — Linux Fundamentals & Systems Administration
- What A Process Is — Linux Fundamentals & Systems Administration
- Signals, And What kill Really Sends — Linux Fundamentals & Systems Administration
- Job Control, And Processes That Outlive You — Linux Fundamentals & Systems Administration
- The Diagnostic Ladder: Is It Up, Is It Named, Is It Routed — Linux Fundamentals & Systems Administration
- Node.js Process Architecture: Memory & Heap Spaces — Node.js Internals & Backend Services
- Close Phase & Signal Dispatch: Sockets & Teardown — Node.js Internals & Backend Services
- Child Processes: spawn, execFile, fork & IPC — Node.js Internals & Backend Services
- Dictionaries And String Formatting — Hands-on Python: Complete Video Course & Book
- Accumulation Loops — Hands-on Python: Complete Video Course & Book
- Appending To Lists, Sets, Constructors — Hands-on Python: Complete Video Course & Book
- Composing Web Pages In Python — Hands-on Python: Complete Video Course & Book
- CGI: Dynamic Web Pages — Hands-on Python: Complete Video Course & Book
- Alert Triage, False Positive Reduction & Fatigue Mitigation — Security Operations & Threat Hunting (SOC)
- SIEM Architecture: Ingestion Pipelines & Indexing — Security Operations & Threat Hunting (SOC)
- SOC Runbooks, Shift Handoffs & Escalation Paths — Security Operations & Threat Hunting (SOC)
- Threat Intelligence Platforms & STIX/TAXII Ingestion — Security Operations & Threat Hunting (SOC)
- Detection as Code: Authoring & Testing Sigma Rules — Security Operations & Threat Hunting (SOC)
- Windows Event Logs, Sysmon & Linux Auditd Telemetry — Security Operations & Threat Hunting (SOC)
- YARA Rule Authoring & File Signature Matching — Security Operations & Threat Hunting (SOC)
- Cyber Kill Chain vs MITRE ATT&CK Framework — Security Operations & Threat Hunting (SOC)
- Adversary Tactics, Techniques & Procedures (TTP) Mapping — Security Operations & Threat Hunting (SOC)
- Post-Incident Review & Root Cause Analysis — Security Operations & Threat Hunting (SOC)
- Forensics Principles, Custody & Imaging — Security Operations & Threat Hunting (SOC)
- Memory Forensics: Process Trees & Injection — Security Operations & Threat Hunting (SOC)
- Malware Triage: Hashes, Strings & Sandboxing — Security Operations & Threat Hunting (SOC)
- The Environment Variable Trap — Application Security & Threat Modeling for Engineers
- Container Security: Minimal Bases And Non Root — Application Security & Threat Modeling for Engineers
- The Storage Decision: Relational Versus Document — Scalable System Design & Distributed Architecture
- Caching Strategies And Topology — Scalable System Design & Distributed Architecture
- Queues, Events And Asynchronous Work — Scalable System Design & Distributed Architecture
- Idempotency, And Exactly Once As A Fiction — Scalable System Design & Distributed Architecture
- Load Balancing And The Failure Modes It Introduces — Scalable System Design & Distributed Architecture
- Timeouts, And Avoiding Cascaded Failure — Scalable System Design & Distributed Architecture
- Backpressure And Load Shedding — Scalable System Design & Distributed Architecture
- Monolith Versus Services: The Honest Trade Offs — Scalable System Design & Distributed Architecture
- Capacity Planning As A Design Input — Scalable System Design & Distributed Architecture
- Worked Design One: Ticket Booking, Correctness First — Scalable System Design & Distributed Architecture
- Worked Design Two: Scaling Chat Fan Out — Scalable System Design & Distributed Architecture
- Worked Design Three: A Metrics Ingestion Pipeline — Scalable System Design & Distributed Architecture
- Graded On A Machine You Never Touched — RHCE in Ansible (EX294): Automate Red Hat Systems
- ansible.cfg: Which File Wins, And The Settings That Matter — RHCE in Ansible (EX294): Automate Red Hat Systems
- requirements.yml: Installing Roles And Collections — RHCE in Ansible (EX294): Automate Red Hat Systems
References
- NIST glossary: process
- credentials(7) manual page: process identifiers
- POSIX definitions: process
- Linux manual: proc(5)
- man7: ps(1)
- os: process parameters
- Linux manual page: pthreads(7)