Recently, the impressive success of the IEEE 802.11 WLAN technology has dramatically changed the role of the wireless connectivity provisioning. Born as a wireless extension of small office or home networks, todays the WLANs are getting more and more popular as a large, even metropolitan, area networks. The deployment of large-scale WLANs has some critical issues, because of the lack of coordinated management functionalities among the network nodes. In this paper we briefly describe the CAPWAP architectural solution, for centralizing some control and maintenance functionalities in large scale WLAN, by guaranteeing the interoperability between network nodes provided by different vendors. We also investigate on a simple and efficient application for optimizing the wireless network resources, which is possible thanks to the centralization of some control operations. In particular, we propose an automatic frequency planning algorithm, not requiring any network administrator aids, which we tested via simulation and we implemented in an actual testbed.