The best way I have found is to do the following.
Dig a small hole and fill it with ashes.
Surround the hole with Peas -- fresh or frozen doesn't matter
When the bear comes to take a pea, kick it in the ash hole.
Good luck. Unless it is a Grizzley, don't worry.