Make login compatible

Now let's try to find out why ping not always work.