Not able to access the shell due to this error?

$ ssh serve1.server1.com
5:47pm up 35 days, 16:42, 0 users, load average: 3.78, 3.23, 3.72
stdin: is not a tty

Its due to mesg y line which you can find in /etc/bashrc or in ~/.bashrc or ~/.profile file. comment the line and you will be good to be at the shell prompt.