Houses and rooms are full of perfumes, the shelves are crowded with perfumes.
In this first example of a metaphor, the "perfumes" represent memories. Indeed, it is often said that the sense of smell is the sense most closely linked to memory. The particular smell of a room or a house, for example, can evoke memories of moments spent in that room or house. Likewise, each book on a shelf contains memories, and thus the shelves are "crowded with perfumes."
You shall no longer . . . look through the eyes of the dead, nor feed on the spectres in books.
In this second example of a metaphor, Whitman is encouraging people to live life directly, rather than through books. The "dead" he refers to possibly represent dead authors or characters in books that are never really alive. He also refers to these "dead" authors or characters as "spectres," compounding the idea that they are not alive in the here and now. They are "spectres" from the past. Spectres are also insubstantial, and thus to "feed" on them is poor nourishment for one's mind.
This is the grass that grows wherever the land is and the Water is, / This the common air that bathes the globe.
In this third example from stanza seventeen, Whitman metaphorically describes the thoughts that he has been outlining previously in the poem as "the grass," "the Water," and "the common air." In other words, Whitman implies that thoughts about life and thoughts about who we are and what we might be are as common, as natural, and as ubiquitous as "the grass," "the Water," and "the common air." We should not neglect these thoughts, as we should not neglect the elements that sustain us—rather, we should celebrate and embrace them.