Reposting a reply I made in a thread early this year:
Ebooks will be preserved the same way that paper books are-- with effort, by people who care about their survival. Do you think that, once produced, paper books last forever without assistance? They don't. They have to be stored inside buildings-- buildings that must be maintained (a leaky roof will destroy a book as easily as leaving it in the rain.) There has to be someone to keep them away from the rats, and the roaches, and the silverfish, and from sunlight (which will fade the ink and crumble the pages.) They have to avoid being used by people who are less literate or more desperate for fires or for toilet paper, or simply tossed away to make space. They have to survive readers who brutalize them by writing in them and dog-earing pages. They have to be handled carefully or repaired when their glue crumbles, or the pages are made fragile by acid.
Keeping books takes effort. There are many, many works of fiction and non-fiction lost in the past, not because they were electronic versions, but because there were too few copies, or too little interest in preserving them, or
some monk wanted a prayer book or some encroaching culture/religion
wanted the books of the old culture/religion destroyed, or the language died, or the people were too damn busy dealing with war, famine, or collapse of their civilization to bother with them.
Here's what will happen if the power grid goes out-- the majority of the population of the world will die. Those who survive will be the toughest and those already so poor they didn't much notice the difference. There will no longer be taxes to run the governments, and there will no longer be governments to run the libraries. The people will be too busy trying to not die to worry about pampering books. If the power grid goes out, or WWIII happens, the majority of paper books will be moldy, sodden lumps or ashes within one or two generations. Anyone who thinks that, post-apocalypse, digital books will disappear and paper books will be alive and well either isn't thinking or is pushing an emotional argument.
So-- there are TWO things needed for both paper and electronic books-- people who care to make the effort to maintain them, and a civilization for the people to live in.