Question: In *Donkey Kong 64*, one of the minigames is "Beaver Bother" where you try to herd beavers into a hole. I've tried this a whole bunch and am having a really hard time beating it.

My strategy has been pretty much to just run up to the beaver closest to the hole and spam the B button, which the tutorial says is supposed to scare them. I don't see any visible evidence that it is working. What usually happens is the beaver will just stay near the hole, but not fall in, then go to either the right or left away from the hole. I've tried shoving the beavers in as well, but that doesn't seem to work. Jumping (A button) seems useless to me, so I haven't used it.

What is the trick to beating this minigame?

Answer: 
There's not much of a secret as there's only so many things you can do. You have the right idea to try and get the ones in that are closest to the hole, however, the way in which you move may make a difference in how it is panning out. If you go straight at them, it does very little to nothing, but if you move toward them from the side, they will run away. Follow the circle around and around fairly closely and wrap your circle around the nearest beaver. They will move toward the hole.

Here's a great example of somebody who has figured this out: 

And here's somebody doing it completely the wrong way:

So you can see the difference if you watch both.
Both of the videos in the above post get it wrong. You'lll notice, in particular, the "good way" doesn't actually work in the first video; the narrator's method consistently fails even as he's describing why it allegedly works. However, he wins the game because he's, however inadvertently, approximating the method below.

Don't try to "push" individual beavers into the hole. This will not work. Beavers close to the hole fall in at random. You have no control over this. However, you DO have control over how many beavers are close to the hole. The strategy is to run around the beavers and bark them into a circle AROUND the hole. Some of them will randomly fall in, and the more you can herd into the circle, the more of them will stumble in.

It took me a while to sort this out, but it's not a "driving" game, but a "herding" game. You can't drive individual beavers into the whole, but you can herd groups of beavers into the middle of the stage and wait for them to fall in on their own.