Add loading, show login view and update the gid for user.