Your best frend is knowledge about your distance. It's 5 km, and you know that
- You will have to run the whole of it
- You will not need to run more
So, first, you need do save energy for kilometers 2-5, thus do not run your maximum during the first km. Second, you can just stop and relax after you finish the 5-th km, so you can spend the remainder of energy on your last 1 km or 500 meters.
Just remembering this will help.
Speaking about tricks: you can train with a GPS-enabled sports watch or a GPS-enabled phone (e.g. iPhone or Android phone) with a sports app (e.g. Endomondo, RunKeeper, ...). They usually show (or speak out) your "lap" pace. You can set lap length to 1 km or 500 m and try to keep all the laps with the same pace as the first one. It will need some experimenting to find the pace which is not too high and not too low for you.
Then stick to this pace and maybe try to improve it gradually. During the competition you can go for a little higher pace - you will probably know how much you can allow before it kills you, if you have had enough experience training.