Peer-to-peer based (P2P) VoD systems have proven to be an effective solution for scalable video distribution. In P2P VoD, each peer contributes storage to replicate videos and assist video delivery. A fundamental question is how to optimally replicatevideo content across the peers so as to maximize their upload capacity. We study this question within thecontext of a large-scale P2P network where peers are grouped intodifferent geographical regions, and downloading a video across regionsis more expensive than within a region. Our analysis addresses the combined challenge of (1) optimizing the replicaallocation (placement) with respect to an arbitrary stochastic demand distribution, and (2)finding an optimal assignment of video requests to peers. The problem addressed can model other applications including inventory problems. Our main result is that optimal replica placement in single- and multi-region environments is of max percentile nature. We derive optimal algorithms and show that they have low complexity and thus very practical. We use numerical analysis and simulation to evaluate the system performance and study its behavior. Our results can be used to provide valuable insights on the design of P2P VoD systems.