A systematic experimental and numerical investigation of the conditions for the spontaneous formation of laser cavity solitons in broad-area vertical-cavity surface-emitting lasers with frequency-selective feedback by a volume Bragg grating is reported. It is shown that the switching thresholds are controlled by a combination of frequency shifts induced by ambient temperature and Joule heating. The gain level has only a minor influence on the threshold but controls mainly the power of the solitons. At large initial detuning and high threshold gain, the first observed structure can be a high order soliton. In real devices spatial disorder in the cavity length causes a pinning of solitons and a dispersion of thresholds. The experimental observations are in good agreement with numerical simulations taking into account disorder and the coupling of gain and cavity resonance due to Joule heating. In particular, we demonstrate that the existence of the traps explain the spontaneous switch on of the solitons,but do not modify the soliton shape significantly, i.e. the observed solitons are a good approximation of the ones expected in a homogenous system.