initial handling of server terminated connection