It's odd that the earth to the engine or gearbox can be a hair trigger on/off situation. I can recall having earth problems, and having removed the cable and cleaned both surfaces, even then, a quarter turn on the nut could make the difference.
I once also chased a similar starting problem without checking the basics first, and even a new battery, starter motor and solenoid didn't fix it.
That turned out to be a hairline crack in the battery positive cable, so although it appeared to be tight, wasn't. That was my most frustrating overkill fix.