You should be able to delete/move everything other than Uncategorized… the error you were getting on upgrade appears to be related to some recent search performance changes.
There was a commit made yesterday that sounds like it might help avoid the issue you ran into (I’m not a backend developer, just connecting the dots)
https://github.com/discourse/discourse/commit/54cf3c67664a3eccf2e08710474a100a489d3380