The first amendment is referring to "the group of people who are allowed to assemble and only for the purpose of assembling" may do so as individuals.
The second amendment is referring to "the group of people who are allowed to keep and bear arms and only for the purpose of forming as a Militia" may do so as individuals.
(By "allowed" I mean their right is protected.)
Using the phrase "the people" allowed the framers to refer to a group of certain individuals, yet not every individual. And, that group could be composed of different people depending on the right being protected.
For this discussion, I am saying that the Bill of Rights is not granting rights to the people, it is stating what is not being ceded away to the Federal Government.
If, as you say, the 2nd amendment says that the people do not cede the right to keep and bear arms for the purpose of maintaining a civilian militia, and there isn't anywhere else in the Constitution that forbids the people to have arms, then the 9th amendment still allows the people to keep arms whether or not they are a part of a militia.
Would you agree with that?
-PJ