A server with -tp 4 runs six processes
vllm serve starts one API server process. It starts one engine core process, which runs the scheduler and the KV cache manager. The engine core starts one GPU worker for each GPU, four workers for tensor parallel size 4. Six processes in total.
API server
HTTP, tokenizer
engine core
scheduler, KV manager
ZeroMQ
worker 0
GPU 0, rank 0
worker 1
GPU 1, rank 1
worker 2
GPU 2, rank 2
worker 3
GPU 3, rank 3
Count: 1 API server + 1 engine core + 4 workers = 6 processes.