I tried to upgrade from Confluence 3.x to latest 4.x or even 5.0 preview but in all cases I got all wiki pages broken.
The lines/column/character may be different from page to page, but I get this for all pages (or at least of that I checked randomly).
Error: The XML content could not be parsed. There is a problem at line 111, column 139. Parser message: Unexpected character '=' (code 61); expected a semi-colon after the reference for entity 'os_username' at row,col {unknown-source} : 111,139