# How to make Login Events into a Log file

**URL:** <https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264>\
**Category:** Getting advice\
**Tags:** admin-console\
**Created:** [October 30, 2019, 10:53am UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264 "2019-10-30T10:53:24Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ferry](https://avatars.discourse-cdn.com/v4/letter/f/b4bc9f/32.png) [@ferry](https://forum.keycloak.org/u/ferry)\
**Post date:** [October 30, 2019, 10:53am UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264/1 "2019-10-30T10:53:24Z")

</div>

Hi All,

I would like to ask, is there a way to get all this Events and log it into a logging file?  
 ![image](https://global.discourse-cdn.com/free1/uploads/keycloak/original/1X/5f9d83536956d30cb1d036b722f5fdf2132a1e3d.png)

---

<div class="post-metadata">

**Author:** ![dasniko](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/dasniko/32/2969_2.png) [@dasniko](https://forum.keycloak.org/u/dasniko)\
**Post date:** [October 30, 2019, 11:06am UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264/2 "2019-10-30T11:06:05Z")

</div>

All events are being logged by default. Error events are logged on level `ERROR`, all others on level `DEBUG`.  
The default log level configured in the logging subsystem is `INFO`. That’s why you only see error events in the logs by default.  
If you add a logger for everything `org.keycloak.events` related to `DEBUG`, the they will appear.

---

<div class="post-metadata">

**Author:** ![ferry](https://avatars.discourse-cdn.com/v4/letter/f/b4bc9f/32.png) [@ferry](https://forum.keycloak.org/u/ferry)\
**Post date:** [October 30, 2019, 2:58pm UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264/3 "2019-10-30T14:58:29Z")

</div>

It’s working. Thank you so much sir.

---

<div class="post-metadata">

**Author:** ![ferry](https://avatars.discourse-cdn.com/v4/letter/f/b4bc9f/32.png) [@ferry](https://forum.keycloak.org/u/ferry)\
**Post date:** [October 31, 2019, 9:03am UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264/4 "2019-10-31T09:03:53Z")

</div>

Hi sir another question, what if i run in domain.sh --host-config=host-master.xml.  
Upon checking the host-master.xml did not have logging, when I tried to add in, I will get error unexpected element, do you know about this?

---

<div class="post-metadata">

**Author:** ![dasniko](https://yyz2.discourse-cdn.com/free1/user_avatar/forum.keycloak.org/dasniko/32/2969_2.png) [@dasniko](https://forum.keycloak.org/u/dasniko)\
**Post date:** [October 31, 2019, 9:21am UTC](https://forum.keycloak.org/t/how-to-make-login-events-into-a-log-file/264/5 "2019-10-31T09:21:30Z")

</div>

Sorry, I don’t have any experience with Wildfly running in domain mode. I always use standalone mode only.
