Home-assistant.log file not created

Hi guys,
I have followed the raspberryPi guide and I have installed hass on my armbian system.
Homeassistant runs using systemctl service without any problem but I cannot see any log file inside the .homeassistant folder
I already check access permission on folder and seems fine. Below the result.

[email protected]:/home/homeassistant/.homeassistant$ ls -l
total 120388
-rw-r--r-- 1 homeassistant homeassistant      1370 Mar 15 06:33 automations.yaml
-rw-r--r-- 1 homeassistant root                244 Mar 15 06:33 binary_sensor.yaml
-rw-r--r-- 1 homeassistant homeassistant      7568 Mar 29 19:33 configuration.yaml
-rwxr-xr-x 1 homeassistant root             191106 Mar 19 12:11 configurator.py
drwxr-xr-x 3 homeassistant root               4096 Mar 15 21:22 custom_components
-rw-r--r-- 1 homeassistant homeassistant      2762 Mar 17 19:33 customize.yaml
drwxr-xr-x 2 homeassistant homeassistant      4096 Mar 15 21:10 deps
-rw-r--r-- 1 homeassistant homeassistant      2852 Mar 29 19:42 groups.yaml
-rw-r--r-- 1 homeassistant homeassistant 123015168 Mar 29 19:45 home-assistant_v2.db
-rw-r--r-- 1 homeassistant root                 95 Mar 20 02:29 panels.yaml
drwxr-xr-x 2 homeassistant root               4096 Mar 15 21:22 scripts
-rw-r--r-- 1 homeassistant homeassistant         3 Mar 15 06:33 scripts.yaml
-rw-r--r-- 1 homeassistant homeassistant       696 Mar 16 19:35 secrets.yaml
-rw-r--r-- 1 homeassistant root               3144 Mar 29 19:42 sensors.yaml
-rw-r--r-- 1 homeassistant root                366 Mar 20 01:41 settings.conf
-rw-r--r-- 1 homeassistant root                172 Mar 15 06:33 switches.yaml
drwxr-xr-x 2 homeassistant homeassistant      4096 Mar 15 21:13 tts
[email protected]:/home/homeassistant$ ls -a -l
total 44
drwxr-xr-x  7 homeassistant homeassistant 4096 Mar 28 19:48 .
drwxr-xr-x  4 root          root          4096 Mar 15 21:07 ..
-rw-------  1 homeassistant homeassistant  758 Mar 28 19:48 .bash_history
-rw-r--r--  1 homeassistant homeassistant  220 May 15  2017 .bash_logout
-rw-r--r--  1 homeassistant homeassistant 3526 May 15  2017 .bashrc
drwx------  3 homeassistant homeassistant 4096 Mar 15 21:08 .cache
drwxr-xr-x  7 homeassistant homeassistant 4096 Mar 29 19:48 .homeassistant
drwx------ 10 homeassistant homeassistant 4096 Mar 16 14:39 Maildir
drwxr-xr-x  2 homeassistant homeassistant 4096 Mar 28 19:48 .nano
-rw-r--r--  1 homeassistant homeassistant  675 May 15  2017 .profile
drwx------  2 homeassistant homeassistant 4096 Mar 16 11:25 .ssh

Do you have any hint to find out what’s going wrong?

Try to create the file with touch home-assistant.log while logged in as the homeassistant user.

I’m curious why some files are owned by group ‘root’

I think the default user is “pi” who can’t modify the files, so many of the docs out there say to “sudo” to “root” to do this or that. Before moving to hass.io I would modify files and change the owner/group to homeassistant.

I have tried both creating an empty file inside .homeassistant folder and changing group ownership but the result is still the same.

[email protected]:/home/homeassistant/.homeassistant$ ls -l
total 120660
-rw-r--r-- 1 homeassistant homeassistant      1370 Mar 15 06:33 automations.yaml
-rw-r--r-- 1 homeassistant homeassistant       244 Mar 15 06:33 binary_sensor.yaml
-rw-r--r-- 1 homeassistant homeassistant      8777 Mar 29 22:43 configuration.yaml
-rwxr-xr-x 1 homeassistant homeassistant    191106 Mar 19 12:11 configurator.py
drwxr-xr-x 3 homeassistant homeassistant      4096 Mar 15 21:22 custom_components
-rw-r--r-- 1 homeassistant homeassistant      2762 Mar 17 19:33 customize.yaml
drwxr-xr-x 2 homeassistant homeassistant      4096 Mar 15 21:10 deps
-rw-r--r-- 1 homeassistant homeassistant      2852 Mar 29 19:42 groups.yaml
-rw-r--r-- 1 homeassistant homeassistant         0 Mar 29 22:38 home-assistant.log
-rw-r--r-- 1 homeassistant homeassistant 123289600 Mar 29 22:46 home-assistant_v2.db
-rw-r--r-- 1 homeassistant homeassistant        95 Mar 20 02:29 panels.yaml
drwxr-xr-x 2 homeassistant homeassistant      4096 Mar 15 21:22 scripts
-rw-r--r-- 1 homeassistant homeassistant         3 Mar 15 06:33 scripts.yaml
-rw-r--r-- 1 homeassistant homeassistant       696 Mar 16 19:35 secrets.yaml
-rw-r--r-- 1 homeassistant homeassistant      3144 Mar 29 19:42 sensors.yaml
-rw-r--r-- 1 homeassistant homeassistant       366 Mar 20 01:41 settings.conf
-rw-r--r-- 1 homeassistant homeassistant       172 Mar 15 06:33 switches.yaml
drwxr-xr-x 2 homeassistant homeassistant      4096 Mar 15 21:13 tts

Have you actually added the logger component to your configuration?

Yes, I have configured the logger in configuration.yaml:

logger:
  default: critical
  logs:
    homeassistant.components.alarm_control_panel.ialarm: error

I actually had the same issue, but when I deleted the logger component, it started working again

You’re right! Really strange, if I set it back I cannot see the log file again…Why is it happening?

Maybe because your default log level is Critical and you don’t have any critical entry to log… Try changing the log level to Info, reboot and see if the log file appears.

1 Like