The power of the eight gates was probably found out by the senju, but the actual gates themselves were likely never seen until the Hyuuga clan joined with them to create Konoha. They would be the only ones capable of seeing the actual gates themselves.
As for how they figured out that the 8th gate grants power greater than even a kage and also causes death, I'm guessing that after watching the power of the gates in action, they realized that the amount of power/chakra granted and, conversely, the damage done to the body increases with each gate opened and that the final gate, which is located at the heart, would grant the user tremendous power, but at the cost of user's life from both chakra exhaustion and heart failure.
For all we know, they might have actually seen the 8th gate in action once before and learned from that experience.