Marta B. answered 04/01/19
Proofreader with 30+ years of academic and published experience
Thoreau is writing with "tongue in cheek". You are entirely correct that the word means the opposite of what you would expect in this sentence. Since he is talking about "hinderances to the elevation of mankind", we would expect the word dispensable to be used in this sentence. But his juxtaposition of these two parts of the sentence is meant to be ironic. In "Walden", Thoreau has gone back to nature in the Massachusetts woods and contemplates what he finds as he lives simply. He argues in this book that he finds meaning of life that is elevated or superior to how people normally live their lives in the society as it is structured and organized in the time he is writing. He holds up modern conveniences as impediments to our understanding and full contemplation of the important things in life.