I've written a books worth of stuff on this forum for this very subject. I will try and be brief to keep it short (yah right!).
At the Cub Level we must understand that while the program is for the boys, success depends on keeping the adults interested. If the adults (parents and leaders) are having fun and enjoying the program, there is a 99% likelihood of the boys reaching Webelos and crossing over to the Troops.
In my research, the primary reason for the membership drop at the cub level is adult burnout. Burnout is the loss of motivation and energy to provide a fun program. Five years is way way way too much to expect from volunteers.
At the troop level there are two areas of large membership losses.
The first is the first year scout. More scouts are lost in this age group than any other age group of scouts in all of the BSA. The reason I found is because the huge jump of a 10 year going from a adult guided lifestyle to a patrol method independent decision making lifestyle is terrifying. Imagine a boy who may have never camped in his life being told to pack up for a campout with a troop of strangers. These boys need some time to spool up the confidence that they are safe in the troop even while setting up a tent in the deep dark woods.
The other larger problem I found in my research are the loss of older scouts. I believe the success of the whole troop program is based from the success of the 14 and older part of the program. The over all problem with the 'majority' of troops is they tend to drive their program toward what I call is a First Class Advancement program. The vast majority of the troops activities are designed for scouts to advance up to a First Class level. Actually many troops drive it toward Eagle, but it is the same problem.
A troop that develops activities for advancement works out OK for 10 to 13 year old scouts because they are basically followers and the activities that to them are new and fun. But scouts after puberty have a different natural instinct that drives them more toward taking care of their gang and controlling their future. They simply have the same instincts as adults. The problem with most troops is they don't know how to use that instinct because they still think of older scouts as adolescent boys. So the adults typically assign the older scout to only teach, what, FIRST CLASS SKILLS. Yep, the older scouts are repeating their first three years all over again. Older scouts want responsibility in developing boys into men, not babysitting scouts in classroom type settings.
The problem is we are told over and over to let the older scouts teach so they are doing adult responsibilities. But teaching in a class room type of environment isn't really an adult responsibility. It is just plain boring. So the older scouts drop out and the older scouts of the troop don't typically last longer than age 14.
Troop adults need to develop the program so that First Class skills are not developed in class room type setting, but instead through passive actions during adventure activities. The program needs to get away from advancement themes so that the scout develop more of their survival skills like backpacking, canoeing, camping, hiking, bicycle riding and on and on. You know, the fun stuff. The older scouts leading those activities don't feel trapped in the same ol same ol program of previous years and they aren't babysitters. The program needs to be developed so that younger scouts learn "everything" from the role models of older scouts. That may sound simple, but it goes against the nature of a protective parent. It takes as much practice for the adults to stand back as it does for scouts to step forward. But in short, it comes down to a fun program. And it's the older scouts who define fun, not the younger ones. Like the Cub program, if the older scouts are excited about the program, the younger ones will follow.
That is a very brief in my limited time description of my experience and research of how units succeed and fail. I can fill in the gaps if you would like more detail.