Guide: How to log to Synology

Topics (not sure which fora)
when not sure where to post, post here and mods will move it to right forum.
Post Reply
Holland
Posts: 353
Joined: Friday 12 July 2013 13:53
Target OS: Raspberry Pi
Domoticz version: Beta Ch
Location: The Netherlands
Contact:

Guide: How to log to Synology

Post by Holland » Sunday 17 April 2016 22:48

Please find below a few steps to get logging to the loggingcenter of a Synology working. It's pretty simple, it just takes 3 steps. I know there are a few wiki's already created for this purpose, but I could not make it work using those wiki''s. So maybe the below is helpful for someone;

1. Check if the Log Center is installed on the NAS.
2. At the following line to the Domoticz startup script, and restart Domoticz : /etc/init.d/domoticz.sh


DAEMON_ARGS="-loglevel 0 -syslog local1 -daemon -www 8080"

My daemon section looks like this, changed are marked bold;


DAEMON=/home/$USERNAME/domoticz/$NAME
#DAEMON_ARGS="-daemon"
#DAEMON_ARGS="$DAEMON_ARGS -daemonname $NAME -pidfile $PIDFILE"
#DAEMON_ARGS="$DAEMON_ARGS -www 8080"
DAEMON_ARGS="$DAEMON_ARGS -sslwww 443"
DAEMON_ARGS="-loglevel 0 -syslog local1 -daemon -www 8080"
#DAEMON_ARGS="$DAEMON_ARGS -log /tmp/domoticz.txt"
#DAEMON_ARGS="$DAEMON_ARGS -syslog"

3. Make a change in the rsyslog service config file

Jump to /etc/
And edit rsyslog.conf

add the following just above the Global Directives section, where ip is the ip of the Synology. After the below is added restart the rsys service, and have a look on you NAS, info should flow in already. That's all!

*.* @ip:514

annefmoreno
Posts: 5
Joined: Friday 22 April 2016 12:18
Target OS: Windows
Domoticz version:
Contact:

Re: Guide: How to log to Synology

Post by annefmoreno » Saturday 23 April 2016 7:20

Synology is a Taiwanese corporation that specializes in network attached storage (NAS) appliances. Synology’s line of NAS are known as the DiskStation for desktop models, and RackStation for rack-mount models. Synology's products are distributed worldwide and localized in several languages. Synology's headquarters are located in Taipei, Taiwan with subsidiaries located around the world.

woody4165
Posts: 530
Joined: Monday 14 March 2016 14:55
Target OS: Linux
Domoticz version: beta
Location: Rome, Italy
Contact:

Re: Guide: How to log to Synology

Post by woody4165 » Saturday 23 April 2016 7:44

Hi

nice info.

Just tried also on another NAS brand and it's working.

What if the NAS is down for any reason, just loose the log or is there any issue?

Thanks
Cubietruck - Linux cubietruck 4.13.16 (Debian GNU/Linux 8 (jessie)) + Domoticz + RFLink, Xiaomi Gateway, Owl USB, Yeelight Color and B/W, ESP8266, Broadlink RM2, Netatmo Thermostat

User avatar
jannl
Posts: 955
Joined: Thursday 02 October 2014 6:36
Target OS: Raspberry Pi
Domoticz version: Beta
Location: Geleen
Contact:

Re: Guide: How to log to Synology

Post by jannl » Friday 12 August 2016 8:11

Just came across this post via another thread.

Remember the loglevel line in the example is only present for now in the beta!!

And as as for me, in the latest stable not much logging is send to my Synology NAS

niclasc
Posts: 63
Joined: Wednesday 09 December 2015 18:04
Target OS: Raspberry Pi
Domoticz version: 4.9700
Location: Sweden
Contact:

Re: Guide: How to log to Synology

Post by niclasc » Wednesday 30 August 2017 17:55

Sorry to dig up this old thread. But I have followed this guide to set up logging to my synology but nothing shows up.

I've added this to rsyslog.conf
*.* @192.168.1.10:514

Have this in domoticz.sh
DAEMON=/home/$USERNAME/domoticz/$NAME
#DAEMON_ARGS="-daemon"
#DAEMON_ARGS="$DAEMON_ARGS -daemonname $NAME -pidfile $PIDFILE"
#DAEMON_ARGS="$DAEMON_ARGS -www 8080"
DAEMON_ARGS="$DAEMON_ARGS -sslwww 443"
DAEMON_ARGS="-loglevel 0 -syslog local1 -daemon -www 8080"
#DAEMON_ARGS="$DAEMON_ARGS -log /tmp/domoticz.txt"
#DAEMON_ARGS="$DAEMON_ARGS -syslog"

And have my synology log center set up with:
BSD format settings
TCP and port 514

Domoticz is v3.8342

nono212
Posts: 30
Joined: Sunday 18 December 2016 14:47
Target OS: Linux
Domoticz version: 3.6179
Contact:

Re: Guide: How to log to Synology

Post by nono212 » Wednesday 03 October 2018 18:00

Hello
I have Domoticz with Jahdal image and I want the domoticz.log to be sent to the log server of Synology is it possible?

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests