We are told that they can only terminate on surfaces, grain boundaries or other dislocations but we are not told why they can't terminate inside the crystal.
The answer is topology. Dislocation is a topological defect - there is a conserved quantity that measures how many lattice points you "skip" when you go around (burgers vector). That misalignment cannot just disappear. Imagine going twice north, twice east, twice south, three times west and arriving at the same point. That defines a crooked lattice "square" that encircles the dislocation. Now move along the dislocation (the third dimension, perpendicular to this "map") - every time you move by a single lattice point in that direction, neighbors are still neighbors and there will always be one extra step in one direction (even if the crystal twists and the east-west direction is now at an angle). This can only end on a surface or a different kind of defect. There are conservation laws different for each lattice and material type, that basically just count the conserved quantities and tell you how they add together when two defects meet.
Energy has nothing to do with this whatsoever. The only thing that matters is local order: each type of local organization has its own topological rules for defects (which disappear when order disappears, e.g. at a phase transition).
Compare this to knots on a string - you can only remove it if you get it to the end of the string. Or how you can't get a kink out of your headphones while you're holding both ends.