To fix this issue, I, personally would:
Draw a circle around the barrel. The ideal place you want your horse's feet to be while running the course. Be sure to allow room between the barrel and feet so he can have balance without running into the barrel. Work this circle at a walk, trot, and canter. Be sure to treat these practices just as you would if you were running. For instance, make sure you have to correct lift of the shoulder and that your horse knows where his feet are. Once he is "hugging the barrel" like you want him to, start doing the pattern like this, drawing circles around all three barrels. First walk, then trot, then canter. If at any point he starts to stray from your circles, circle around that barrel until he is on your line again.
Now, whenever you run him, make sure he stays on your line. Check his shoulder and his leads. If at any time he strays, canter around it a few times, making sure he's on your circle. He should learn by habit that that is where he puts his feet, if you allow him to learn it.
Just do other things, too. Make it interesting. I hated running my horse in endless cloverleafs. You can practice on trees while your out on the trail... anything.
Hope this helped.
I got summer hating on me cause I'm hotter than the sun. Win-ter hating on me cause I'm colder than ya'll. I'm being hated by the seasons so forget ya'll who hating for no reason!