The increasing trend of global IP traffic is mainly driven by high-definition video services and cloud computing and storage. Moreover, to maintain a high quality of service in content delivery networking, data are geographically replicated in data centers distributed within network topologies. Thus, data centers are an emerging scenario for research and development aimed at energy-efficient transmission and networking solutions. Previous research work has focused on intradata center energy efficiency while interdata center energy issues have not been extensively analyzed yet. We propose heuristics and meta-heuristics for optimal placement of data centers with minimum power consumption over a network topology relying on flex-grid spectral use. In order to minimize the network’s power consumption, we have performed a detailed comparison of heuristic and meta-heuristic designs for different network scenarios based on real topologies. Moreover, our results show that meta-heuristic provides an optimum data center placement in a reasonable amount of time for a small- to medium-sized network.