I belive Gandalf must have heard of "Durin's Bane" and knew full well what it
was. But at the time of the Fellowship's journey, it was very ancient
history, and Moria was a very big place.
As others have mentioned, it was Gandalf who pressed for going through
Moria. I believe his motivation was to go 'under cover,' shorten the
journey, and avoid the Gap of Rohan rather than to confront the Balrog.
If Gandalf had meant to confront the Balrog, I don't think he would have
exposed the rest of the Fellowship, and certainly not the Ringbearer, to such a
dire danger.
To wit, even after being confronted by the couter-spells of the power on the
other side of the door of the chamber, I still don't think he knew for sure it
was a Balrog. Highly suspected, yes; but he didn't know for sure until he
saw
it.
"I don't suffer from insanity...I enjoy every minute of it!"