Lending existing copies does not prevent copying. I have come across plenty of "pirated" physical copies of various literature sold for a fraction of the actual cost.
Who said anything about preventing copying? I'm just saying that the way libraries operate does not involve making their own copies, which is a (and I would say the) significant difference from file sharing, in terms of morality and legality.
That is an important point which you are not seeing. I can share a file (an ebook) with my "friend" which i acquired legitimately. He then makes a copy of it and distributes it via a file sharing site.
Similarly, I can borrow a book from a public library and make digital copies of it and distribute it. In fact some illegal copies of ebooks you find on file sharing sites are scanned copies of legitimately acquired physical copies (I have personally come across comics with library seals in one of the scanned pirated digital copies). Some pirates also distribute colored xerox copies of physical copies acquired from libraries.
The only difference between the two is time taken to do it.
I understand all of that, but how is it relevant to the question of the utility, legality, and morality of libraries and file sharing? The fact that people can do legally or morally questionable things with the stuff they borrow from libraries has no real bearing on the legality or morality of the libraries themselves.
Can't the same be said for file sharing sites? Why hold the file sharing sites accountable and question it's legality or morality when its the responsibility of the people (the user in this case) to be legally or morally accountable. Unless the file sharing sites themselves are uploading illegal items (like Grooveshark) I strongly believe you can't hold the site accountable. Libraries aren't held accountable for piracy that is caused because of it. When I see an ebook that has a library seal I wonder what kind of people the Library is lending books to. Is there any background checks done at all? When no one cares about that aspect why suddenly care about the morality and legality of file sharing sites? Its just hypocrisy at its best.
All I'm trying to say is that you need to see the bigger picture. When it comes to file sharing people talk about "millions" of times the particular file has been downloaded only because such a statistic is easily available. Nobody questions that when it comes to Libraries lending out copies because no one looks at what happens in between the time the copy is lent and returned. Can you find any statistic that tells you how many of the "lent" library books have been pirated? For physical book pirates, libraries are a boon. They get access to thousands of books for free/cheap.