The Library The Library was a planet - sized library that was built during the 50th century . It contained every book ever written . Within its core was the Data Core , the largest hard drive ever designed to date , which served as an index computer , as well as containing backup copies of every book ever written . The planet had one moon , which was actually an antiviral subroutine having the physical appearance of a moon . Due to its caretaking role , it was known as a Doctor Moon . History . Creation . The Library and its computer was built by Felman Lux to embody his daughter Charlotte Lux ' living mind before her failing body died . She could enjoy eternal life in the virtual reality , with the Doctor Moon nurturing her spiritual and mental well - being . To protect her identity and their child , the Lux family made the Library computers refer to her by the protracted name " CAL " to define the heart of its computer network . ( TV : " Forest of the Dead " ) It was managed by a head Librarian . Visitors to the Library used courtesy node s , sculpted computer terminals containing real faces made from donated flesh ; the nodes would chose a face they thought a patron would like . The security drones were levitating wooden spheres . All spheres had a camera lens and could communicate by displaying messages across a scrolling LED display in red letters . Visitors were advised to switch off their mobile comm units for the courtesy of other patrons in the library . Paper editions of every book ever written were made specially for the Library . ( TV : " Silence in the Library " ) The forests cut down to make the books were home to Vashta Nerada , which then hatched from the books and infested the Library . When the Vashta Nerada hit their hatching cycle and began their attack , the Doctor believed someone in the Library set off an alarm that made the computer teleport everyone out of its halls and covert them into a virtual form for transmission to a safe location . However , the computer could not reconstitute anyone back to physical form , because it had no place to send them where they would be out of reach from the Vashta Nerada . Instead , the computer managed to " save " all 4022 visitors at the time to its hard drive , where they could dream an imperfect virtual existence . The virtual world was a false reality governed by fake perceptions of time and individuals , maintained by Doctor Moon , who would reassure its population there was nothing to fear , even if he had to alter memories . They would remain cut off from the real world for a century . ( TV : " Forest of the Dead " ) Arrival of the Doctor and River Song . The computer sealed off the planet to quarantine the Vashta Nerada , and it would be 100 years before the Lux family could arrange an archaeological expedition led by Professor River Song to get back inside the Library . The Tenth Doctor and Donna Noble arrived after being asked to come by River Song , via the Doctor ' s psychic paper . River ' s expedition crew was gradually picked off and devoured by the Vashta Nerada , who began stalking the group for meat . Miss Evangelista was the first victim , followed by Proper Dave , ( TV : " Silence in the Library " ) Other Dave , and finally , Anita . Wanting to save Donna , the Doctor tried to teleport her back to the TARDIS but she was accidentally beamed into the data core . Doctor Moon , in the form of his caretaker avatar , set up a fantasy life where she could be married and have children , but this was soon unmasked by Miss Evangelista . Her fading data ghost had been intercepted by the Library and placed into the virtual world , but it was corrupted due to being captured as it was fading away , resulting in a disfigured appearance and a staunch IQ boost . She helped Donna see through the virtual existence and reclaim her grip on the physical world . After realising what CAL had done , the Doctor set about freeing the people trapped in the data core . After reading in the books on the Doctor ' s fearsome reputation , the Vashta Nerada agreed to a deal with him : they gave him a day to get everyone safely off the planet and he ' d make sure the Library would be left alone for them to wander . However , the computer systems lacked the memory capacity to restore all the visitors . The Doctor attempted to use his own memory space to provide the massive transfer , but River intervened by force , knowing it would kill him . Instead , she gave her life to provide the computer enough memory to return all 4 , 022 people and Donna to the real world , resulting in the loss of her physical body . Luckily , the Doctor ' s future self retroactively planned out a way to save her from death . River ' s data ghost was stored on his future self ' s sonic screwdriver , which his present incarnation found and uploaded to CAL . River would be able to live on with her expedition crew , whose ghosts had also been captured by the computer . As the Doctor repaired the data core , Miss Evangelista also regained her appropriate looks . River then took care of CAL and two of the virtual world ' s children as her family . ( TV : " Forest of the Dead " ) Despite River wishing for a proper goodbye from her Doctor , he never visited the Library as he felt it would be too hard to see her again . ( TV : " The Name of the Doctor " ) After entering the Doctor ' s time stream , a copy of Clara Oswald ended up in the Library , watching the Tenth Doctor . ( TV : " The Name of the Doctor " ) At some point after being uploaded to the Library computer , River ' s data ghost was able to link into a psychic " conference call " initiated by the Paternoster Gang to discuss Clarence DeMarco ' s message . After the " call " ended , River kept the line open between her and Clara Oswald , allowing her data ghost to project itself outside the Library to guide Clara through Trenzalore . The Doctor later displayed the ability to see this projection of River to her surprise . After getting the final goodbye she wanted , River ' s data ghost faded back into the Library computers . ( TV : " The Name of the Doctor " ) Later visit by the Doctor . The Eleventh Doctor and Amy Pond later visited the Library , where they encountered the Book Monster s . ( COMIC : " Booked Up " )