Ok, if you followed the official guide you should have a backup of the code folder and the database. I'd suggest not to delete your current upgraded code+DB, just rename the folder and the DB (use PhpMyAdmin or the CLI to something like suitecrm.8.2.2 and same for the DB. If a solution comes for the CSRF problem, you can test it on this bundle later.
Restore the code in the original folder, and restore the DB: you should be running again SuiteCRM with your old 7.12.8
Later you can test the new version on the renamed code folder, by pointing Apache to it or, if possible, creating a new vhost pointing to it. You'll have to change the the DB name in the config file in the renamed folder:
in order to use the renamed DB, also check there's no reference to the DB in
See here: https://community.suitecrm.com/t/how-to-change-database-settings-for-a-cloned-suitecrm-instance/39398
It should work for you version 7.12.8
I experience the same problem. How to rollback to version 8.2.1?
Well, it depends on how you handle your installation, I usually make a full backup (folder.tar.gz + DB.sql) right before upgrading. If something's wrong, I delete the upgraded folder+DB and restore the old ones from backup.
A better solution would be to run a separate instance+db (copied on the fly from prod), upgrade that instance and test it, then upgrade the prod instance only if the tests are ok. Actually that should be done by developers before releasing the upgrade, but you cannot always get all the bugs...
Without a backup you probably need to re-install the previous version, but if the upgrade process changed the DB structure you could have problems with the previous version's SQL. I don't know, never tried that way, sorry.
This could help: https://docs.suitecrm.com/8.x/admin/installation-guide/upgrading/
I'm having this same issue after upgrading from 8.2.1 (which was running ok) to 8.2.2
I tried patching \core\backend\Security\CSRFValidationListener.php by commenting out line 96. That made the login possible again, but with no menu at all (just logout), so I had to go back to 8.2.1 from backup.
These CSRF token errors are mentioned by many users, maybe this issue needs to be addressed more thoroughly. Just my 2¢.