It combines a back-of-envelope model (traffic, storage, memory, servers), measurements of the real system, load tests and headroom such as N+1.