Resource Allocation Graph

Visualize process-resource relationships and detect deadlocks

Add Elements

Create Edges

Actions

Status
Create a Resource Allocation Graph by adding processes and resources, then connect them with edges.

About Resource Allocation Graphs

A Resource Allocation Graph (RAG) is a directed graph used to detect deadlocks in operating systems. It visually represents the relationships between processes and resources.

Graph Elements

  • Processes: Represented as circles
  • Resources: Represented as squares
  • Request Edge: Process → Resource (wants to acquire)
  • Assignment Edge: Resource → Process (already allocated)

Deadlock Detection

A deadlock exists in the system if and only if the resource allocation graph contains a cycle.

When a cycle is detected, it indicates that a set of processes are each waiting for resources held by another process in the set, creating a circular wait condition.