The 21 foot rule suggest in a relaxed environment if a person with a knife runs at you then you can not pull out a gun and fire on them before they can get to you. Sounds like the gun user has a problem and just needs to educate himself on options to create new solutions.
Check out this Elite Knife Instructor VS Elite Gun Fighter and his approach to the situation.