While trying to fix mySQL I seem to have made a huge mistake running sudo chmod -R 777 / var/lib/mysql which seemed to have change everything to green folder instead of purple and now even files like sudo won't work.
I am logged onto SSH as a root user. How do I become the "owner" and able to access all the files again?