Well, I bit the bullet ... backed up the db, and then updated the folders table so that LastUpdated date for each record was equal to the min(LastUpdated) date - sufficiently historical. Then resynched files recursive.
Looks like it did good - still haven't investigated thoroughly. I think that files for folders that were listed in the folders table are now all in the files table.
But there are a couple portals not represented in the folders table at all, and doing a recursive re-synch did not add them. <?>
Also if I go to the site settings for portals I am seeing that they do not have skins, containers or logos set anymore - it's all 'none selected' as with a new site.
Even though that is the case, the correct skins, containers and logos seem to be displaying on the portals in question. Rather boggling. Unless it's all just cached somewhere out in internet space and catch up later. But I did a ctl-F5 and the pages still look right.
Hmmm ... well, if I log into the default portal, and view portals from there, and look at settings for each portal, they all show to have the same skin as the default portal, once I re-selected the default portal skin. But if I log into the portal itself, and then view site settings, the correct skins, containers and logos are set there.
Something is still very much not right ...