The issue of what Gandalf knew concerning the destruction of the One Ring is discussed in the answers to [How does Gandalf (or anyone) know how to destroy the Ring?][1]

As for the lesser rings, Gandalf states not only that these could be destroyed by dragons, but that four were in fact destroyed in this way. 

> Seven the Dwarf kings possessed, but three he [Sauron] has recovered, and > the others the dragons have consumed. 

(The Shadow the the Past)

This is supported by the following quote from "Of the Rings of Power and the Third Age" (the Silmarillion):

> It is said that the foundation of each of the Seven Hoards of the
> Dwarf-kings of old was a golden ring; but all these hoards long ago
> were plundered and the Dragons devoured them, and of the Seven Rings,
> some were consumed in fire and some Sauron recovered.

None of this brings us any closer to answering the question: how did Gandalf know this? My best guess is based on this question, which Frodo asks Galadriel:

> I would ask one more thing before we go, ... a thing which I often
> meant to ask Gandalf in Rivendell. I am permitted to wear the One
> Ring: why cannot I see all the others and know the thoughts of those
> that wear them?

(The Mirror of Galadriel). 

The point here is that as bearer of one of the Three, Gandalf may have known something about the bearers of the lesser rings, and perhaps was able to sense their destruction. Speculation of course, but it's the best I have.


  [1]: https://scifi.stackexchange.com/q/166539/4935