# Login with Providers (google,facebook) ERROR

**URL:** <https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321>\
**Category:** Extending the server\
**Tags:** authentication\
**Created:** [April 23, 2020, 1:50pm UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321 "2020-04-23T13:50:07Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![edianogama](https://avatars.discourse-cdn.com/v4/letter/e/b782af/32.png) [@edianogama](https://forum.keycloak.org/u/edianogama)\
**Post date:** [April 23, 2020, 1:50pm UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321/1 "2020-04-23T13:50:08Z")

</div>

Hey everyone,  
Sometimes I get this error when auth with a provider,  
sometimes work, sometimes no.  
Anyone have any ideia what is happening ?

**14:38:07,012 WARN [org.keycloak.events] (default task-73) type=LOGIN\_ERROR, realmId=Dev, clientId=null, userId=null, ipAddress=\*\*\*\*, error=identity\_provider\_login\_failure**

**ERROR [org.keycloak.broker.oidc.AbstractOAuth2IdentityProvider] (default task-73) Failed to make identity provider oauth callback: java.net.UnknownHostException: [oauth2.googleapis.com](http://oauth2.googleapis.com): Name or service not known**

**ERROR [org.keycloak.broker.oidc.AbstractOAuth2IdentityProvider] (default task-73) Failed to make identity provider oauth callback: java.net.UnknownHostException: [graph.facebook.com](http://graph.facebook.com): Name or service not known**

---

<div class="post-metadata">

**Author:** ![edianogama](https://avatars.discourse-cdn.com/v4/letter/e/b782af/32.png) [@edianogama](https://forum.keycloak.org/u/edianogama)\
**Post date:** [April 23, 2020, 2:58pm UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321/2 "2020-04-23T14:58:06Z")

</div>

Update:

just only google return me a error:  
**Failed to make identity provider oauth callback: java.net.UnknownHostException: [oauth2.googleapis.com](http://oauth2.googleapis.com): Name or service not known**

---

<div class="post-metadata">

**Author:** ![ShekharSahu](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/shekharsahu/32/1705_2.png) [@ShekharSahu](https://forum.keycloak.org/u/ShekharSahu)\
**Post date:** [November 18, 2020, 11:58am UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321/3 "2020-11-18T11:58:50Z")

</div>

@edianogama

were you able to solve this issue?

---

<div class="post-metadata">

**Author:** ![seseso](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/seseso/32/4452_2.png) [@seseso](https://forum.keycloak.org/u/seseso)\
**Post date:** [November 22, 2021, 12:31pm UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321/4 "2021-11-22T12:31:05Z")

</div>

I’m hitting the same problem.

---

<div class="post-metadata">

**Author:** ![weltonrodrigo](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/weltonrodrigo/32/3104_2.png) [@weltonrodrigo](https://forum.keycloak.org/u/weltonrodrigo)\
**Post date:** [November 22, 2021, 9:12pm UTC](https://forum.keycloak.org/t/login-with-providers-google-facebook-error/2321/5 "2021-11-22T21:12:38Z")

</div>

Check if your keycloak server can resolve those URL.

**Name or service not known** points definitely to a network problem. That means java could not resolve (turn the hostname into an IP) before doing a request to those services. You should check the dns resolution on the machine where keycloak is running.

If keycloak is running in a vm, try logging into that VM and ping [oauth2.googleapis.com](http://oauth2.googleapis.com)

If it’s a container, try `exec`in a bash into it and pinging.
