With the increasing demand for video streaming applications, HTTP Adaptive Streaming (HAS) technology has become the dominant video delivery technique over the Internet. Current HAS solutions only consider either client- or server-side optimization, which causes many problems in achieving high-quality video, leading to sub-optimal users’ experience and network resource utilization. Recent studies have revealed that network-assisted HAS techniques, by providing a comprehensive view of the network, can lead to more significant gains in HAS system performance. In this paper, we leverage the capability of Software-Define Networking (SDN), Network Function Virtualization (NFV), and edge computing to introduce a CDN-Aware QoE Optimization in SDN-Assisted Adaptive Video Streaming framework called CSDN. We employ virtualized edge entities to collect various information items (e.g., user-, client, CDN- and network-level information) in a time-slotted method. These components then run an optimization model with a new server/segment selection approach in a time-slotted fashion to serve the clients’ requests by selecting optimal cache servers (in terms of fetch and transcoding times). In case of a cache miss, a client’s request is served (i) by an optimal replacement quality (only better quality levels with minimum deviation) from a cache server, (ii) by a quality transcoded from an optimal replacement quality at the edge, or (iii) by the originally requested quality level from the origin server. By means of comprehensive experiments conducted on a real-world large-scale testbed, we demonstrate that CSDN outperforms the state-of-the-art in terms of playback bitrate, the number of quality switches, the number of stalls, and bandwidth usage by at least 7.5%, 19%, 19%, and 63%, respectively.