The recent Advanced LIGO and Advanced Virgo joint observing runs have not claimed a stochastic gravitational-wave background detection, but one expects this to change as the sensitivity of the detectors improves. The challenge of claiming a true detection will be immediately succeeded by the difficulty of relating the signal to the sources that contribute to it. In this paper, we consider backgrounds that comprise compact binary coalescences and additional cosmological sources, and we set simultaneous upper limits on these backgrounds. We find that the Advanced LIGO/Advanced Virgo network, operating at design sensitivity, will not allow for separation of the sources we consider. Third-generation detectors, sensitive to most individual compact binary mergers, can reduce the astrophysical signal via subtraction of individual sources, and potentially reveal a cosmological background. Our Bayesian analysis shows that, assuming a detector network containing Cosmic Explorer and Einstein Telescope and reasonable levels of individual source subtraction, we can detect cosmological signals ωCS(25 Hz)=4.5×10-13 for cosmic strings, and ωBPL(25 Hz)=2.2×10-13 for a broken power-law model of an early Universe phase transition.