added server shutdown and a slightly changed startup behavior to correctly handle false logins