If someone would have to do this job, you can use this code written by me. Just update name of module, computer name of node type ‚page‘ and vocabulary ID (do NOT forget!) and run this code. It should generate hierarchical taxonomy in vocabulary $vid and match nodes to its parents, like in nodehierarchy. It wants a bit of tweaking, not simply copy&paste.