sudo chmod -R 777 /
was entered in an attempt to regain access to directories that were previously accessible, but this caused the SSH connection to be closed and now can no longer be reconnected. A "Login failed." error is displayed. The Pi can still be accessed directly.
Any use of sudo
returns sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set
How can this be reversed? What did the permission changes do to cause this?