In this paper, the notion of a cohesive and self-sufficient grid is proposed. Based on a cohesive and self-sufficient virtual microgrid, an active distribution network is optimally planned, and an optimal configuration of demand-side resources, distributed generations, and energy storage systems are generated. To cope with stochastic uncertainty from forecast error in wind speed and load, flexibility reserves are needed. In this paper, the supply relation between flexibility and uncertainty is quantified and integrated in an innovative index which is defined as cohesion. The optimization objectives are a minimized operational cost and system net-ability cohesion as well as self-sufficiency, which is defined as the abilities both to supply local load and to deal with potential uncertainty. After testing the optimal configuration in the PG&E 69 bus system, it is found that with a more cohesive VM partition, the self-sufficiency of VMs is also increased. Also, a case study on uncertainty-caused system imbalance is carried out to show how flexibility resources are utilized in real-time operational balance.