No meu caso este era o meu problema:
“Check the value of mnet_localhost_id in the mdl_config database table. It’s normally 1 but must match the mnet_hostid field in your user records in the mdl_user table for the user to be recognised. It can sometimes get changed spuriously during upgrades or site migrations.”

Bastou mudar no mdl_config a opção de 3 para 1 e voilá!

http://docs.moodle.org/23/en/Installation_FAQ#I_can.27t_log_in_-_I_just_stay_stuck_on_the_login_screen