One thing I see in log is as follows which I think should be the issue.
Bad item passed to pam_*_item()
This means the file /etc/environment may be corrupted and not allowing to login.
I am getting shell prompt but hanging there.
I am unable to enter any commands in that prompt.
I am unable to interact with hardware.
Is there any recovery mode I can enter?
Kindly help me resolve this issue.