Cache-enabled small base station (SBS) densification is foreseen as a key component of 5G cellular networks. This architecture enables storing popular files at the network edge (i.e., SBS caches), which empowers local communication and alleviates traffic congestion at the core/backhaul network. This paper develops a mathematical framework, based on stochastic geometry, to characterize the hit probability in multi-channel cache-enabled 5G networks with both unicast/multicast capabilities and opportunistic spectrum access. To this end, we first derive the hit probability by characterizing the opportunistic spectrum access success probabilities, service distance distributions, and coverage probabilities. An optimization framework for file caching is then developed to maximize the hit probability. To this end, a simple concave approximation for the hit probability is proposed, which highly reduces the optimization complexity and leads to a closed-form solution. The sub-optimal solution is benchmarked against two widely employed caching distribution schemes, namely, uniform and Zipf caching, through numerical results and extensive simulations. It is shown that the caching strategy should be adapted to the network parameters and capabilities. For instance, diversifying file caching according to the Zipf distribution is better in multicast systems with large number of channels. However, when the number of channels is low and/or the network is restricted to unicast transmissions, it is better to confine caching to the most popular files only.