I've just realized that we've both committed some fundamental errors in this discussion.
First I will try to answer the original question.
When the cannon is free to move,assuming the gunpowder gives a certain fixed amount of energy (say E)...
Cannon (mass M) goes back with V, ball (mass m) forward with v
Using energy conservation: 0.5 M V^2 + 0.5m v^2 = E
Things change in the second case. Cannon can only move with the Earth and together they form an extremely large mass that acquires a negligible velocity.
Using energy conservation: 0.5 (M+mass of earth) V'^2 + 0.5m v'^2 = E
Using the two equations,
0.5 M V^2 + 0.5m v^2 = 0.5 (M+mass of earth) V'^2 + 0.5m v'^2
V' here can be expressed here in terms of v', using conservation of momentum.
From there it should be easy to see that v'>v.
Now. The equation you included in your second post (#3)...
Using conservation of momentum: m1*v1 + m2*v2 = m2*v3
...is wrong. Those are two completely different events you got there in one equation.
Momentum alone cannot be used to prove the result we need here. (so i was wrong with that too)
The assumption that the gunpowder releases a fixed amount of energy both times is also critical.