Why isn’t CERN afraid of a fusion reaction in the LHC?
Proton-proton fusion happens at energies around 15 keV. The LHC currently operates at an energy of 13 TeV, which is literally one billion times larger. Fusion is one of the lowest-energy processes that could occur at the LHC, and most of the interesting reactions that are studied there go way beyond nuclear fusion.
A proton is made up of fundamental, pointlike bits of matter called quarks, held together by force carriers called gluons. These quarks are bound together with a certain binding energy; the quarks are also relatively light, so this binding energy actually makes up most of the mass of the proton. In other words, the binding energy of the proton is roughly equal to the mass of the proton.
When you collide protons at an energy that's far below its mass, the proton acts as a single object. This is the regime in which nuclear physics typically occurs; all of the reactions that break nuclei apart, and the energy that holds them together, are typically small enough that it works to treat the proton as a single unit most of the time. This includes nuclear fusion; the mass of the proton is 938 MeV, and the amount of energy required for nuclear fusion (15 keV, as we said) is tens of thousands of times smaller than that.
If we instead decide to collide protons at energies that are higher than a few times the proton mass, then there is now enough energy in the reaction for the quarks inside the protons to interact with each other directly. We can no longer treat protons as single objects, since the energy involved in the reaction is enough to expose its inner components. As the collision energy becomes higher and higher, the binding energy of the proton becomes less and less relevant, and the picture of two dense clouds of quarks and gluons interacting becomes more and more accurate. These reactions have enough energy to produce all manner of exotic matter, particles that you could never find in a nucleus, nor could you create them by nuclear fusion. The current energy of the LHC is roughly ten thousand times greater than the mass of the proton; at those energies, the proton's mass and binding energy are completely negligible, and the interesting reactions are entirely driven by individual quarks and gluons interacting with each other. The proton is merely a vehicle for us to deliver bits of fundamental matter to the collision site. If there were a way to just collide free quarks and free gluons, without all the mess generated by the proton, many particle physicists would jump at the chance. (Unfortunately, this turns out to be impossible.)
There's certainly lots of extremely interesting physics to do at the nuclear-physics scale, and our understanding of the dynamics of nuclei is the subject of a great deal of active research in other experiments. But that's simply not what the proton-proton collisions at the LHC are meant to explore. The proton-proton collisions are actually better thought of as quark-quark collisions, or quark-gluon collisions, or gluon-gluon collisions. They're not meant to study protons, which is why the protons are often totally destroyed in the collision, transformed into exotic matter which then decays back into ordinary matter. Proton-proton collisions are meant to make conclusions about the interactions of fundamental particles, and that requires acceleration to extremely high energies, far above what you would need, or want, for nuclear fusion.
So, given this, why aren't LHC physicists worried about triggering nuclear fusion? The answer is fairly straightforward: though each individual proton has an energy a billion times larger than the fusion threshold, the total amount of energy that is released into the surrounding area is still rather manageable, on a macroscopic scale. After all, 13 TeV is still only about a microjoule of energy, which is around a billion times less than the amount of energy that the Sun imparts to a square meter of Earth every second. That said, there are around 600 million collisions per second happening, so you definitely don't want to be standing anywhere near the interaction point. This is especially true since the individual particles of radiation released are much higher in average energy, meaning they're much nastier in terms of damage to life and inanimate objects than the radiation from the Sun. Because of this, the detector electronics have to be specially designed to deal with this extreme high-radiation environment; human access to the experimental hardware is also very tightly controlled, and is completely forbidden when the accelerator is running. But ultimately we're talking about around a few kilowatts, at most, of radiation released into the environment at each collision site. That's a pretty human-sized amount of power, and is roughly equivalent to the heating power of a large space heater (but, again, in a much more damaging form than the heat released by a space heater). This was by design - the collision rate at the LHC was chosen partly so that it would be feasible to build a detector that could withstand the influx of radiation. Nuclear explosions require many, many reactions all occurring at once, which is why they have such destructive power. The LHC collides at most a few individual protons at a time.
So, given all this, the LHC would make a terrible fusion reactor. Its energy is much too high to actually reliably trigger nuclear fusion, and the energy released in collisions is miniscule compared to the energy required to keep the beams running, so it would be incredibly inefficient.
As pointed out in the comments, the energy in the LHC is very high. High enough that the interactions are with partons inside the proton, where a parton is any one of the 3 valence quarks (u, u, d), or any of the divergent number of sea quarks, antiquarks, or gluons.
A fusion reaction such as:
$$ p + p \rightarrow d + W^+ \rightarrow d + e^+ +\nu_e $$
is unlikely because the initial state involves 2 coherent protons, and the final state involves a coherent bound deuteron and 2 point leptons.
The energy dependence of such a reaction can be considered with constituent counting rules: basically, you count the number, $n$, of point particles participating in the reaction and get:
$$ \sigma \propto \frac 1 {s^{n-2}} $$
where $s$ is the center of mass energy squared. With 6 quarks in both the initial and final states plus a W-boson in the final state, you get:
$$ \sigma \propto \frac 1 {s^{11}} \propto \frac 1 {E^{22}} $$
This is basically dimensional scaling: the deuteron and each proton is a non-interacting collection of point particles, compressed into a flat disk by Lorentz contraction. The probability of each constituent being close goes as the wavelength squared, or $E^2=s$.
Put another way: the de Broglie wavelength at 7 TeV is 0.000029 fm (a proton is about 1.6 fm across), so you have to select the piece of the proton wave function that has all the quarks that close together, for each proton, and for the final state nucleons as well... and you need a W boson in that tiny disk as well. Anything else and the initial or final states are blown apart.
Given that the temperature in the Sun's core is 1.25 keV, and $\sqrt s = 14 TeV$ at the LHC, fusion should be suppressed by:
$$ f = \big[\frac{1.25\,{\rm keV}}{7\,{\rm TeV}}\big]^{22} \approx 10^{-221}$$
Moreover, the half life of a solar core proton is around 5 billion years, in a "soup" with a density of 100 gram per cc. Comparing this with the LHC interaction point would need knowledge of the spot size and duty cycle... but suffice to say, the time scale for a single fusion reaction is on the order of the life expectancy of our Universe (vs. heat death), plus or minus $10^{100}$.
A simple experimental fact about the LHC is that all reactions of protons on protons happen in vacuum. As the other answers explain, the energy in the beams is too high to allow the two protons to fuse into deuterons , instead the energy "fuses" to generate the particles studied in the experiments. The trajectories of these particles go through detectors depositing energy so as to be able to study the main interaction.
And as a corollary, can they repurpose CERN to become a fusion reactor ?
A reactor means that more energy will come out then spent in generating the beams, and this is not possible with the LHC design, which functions with high energies. There are experiments for colliding beam fusion, and proton proton collisions are not their choice.