DSM 6.2 [Log Centre] Clearing old syslog data entries - IP-addresses / hostnames - in listing for overview.

16
8
NAS
DS1812+ | DSM 7.1.1-42962 U5
Operating system
  1. macOS
  2. Windows
Mobile operating system
  1. Android
  2. iOS
First post here.

I have no clue how and where to clear all the old data entries from past networks and/or devices. To select 3 hostnames for the overview, I have to scroll thru a long list of non existing (anymore) IP-addresses and/or hostnames.

Screenshot 2021-09-18 at 18.38.30.png


I reached out to Synology, but they came back to me with the 'solution' to just reinstall DSM 6.2 over my current DSM 6.2 setup on my DS1812+. Can anyone point me in the right direction - I use macOS Terminal - for clearing these obsolete entries?

Any help greatly appreciated. :cool:
Cheers
 
Thanks for your prompt reply.

I moved all folders for the old hosts log files eg. [macpro51.local] to a seperate drive, just to check the dependency of the folders for the listing in Log Centre. I cleaned out all folders in my syslog shared folder, uninstalled Log Centre rebooted my NAS and reinstalled Log Centre. IP-addresses and hosts still present.

Where did you delete your archives, in the package or in terminal?
 
In Log Center there’s the archive settings. Here you set where in File Station you want it to save logs. Also set to rotate on the shortest settings so the devices are out of the main log.

But it’s not a definitive solution. You could also try filtering the log by devices you want done, and clearing those (hoping the clear action does it on visible logs).
 
Last edited by a moderator:
Here is the exact same issue - 2017- and the best solution so far.


Like I said I reached out to Synology TS, but they gave me the most easy - lazy - answer. Very disappointing from Synology TS! Happy with the solution and now working on deletion of all obsolete records.

Cheers and have a nice evening. :cool:

Here the code I'm using sampled from the post from 2017:

Code:
Last login: Sat Sep 18 19:28:51 on ttys000
MACPRO51:~ ******$ ssh ********@192.168.1.125
********@192.168.1.125's password:
********@DS1812:~$ sudo -i
Password:
root@DS1812:~# cd /var/log/synolog
root@DS1812:/var/log/synolog# dir
total 10180
drwxr-x---  2 system log     4096 Sep 18 20:17 .
drwxr-xr-x 22 root   root   12288 Sep 18 19:53 ..
lrwxrwxrwx  1 root   root      37 Apr  8 14:32 .AFPXFERDB -> /volume1/@database/synolog/.AFPXFERDB
lrwxrwxrwx  1 root   root      39 Apr  8 14:32 .DSMFMXFERDB -> /volume1/@database/synolog/.DSMFMXFERDB
lrwxrwxrwx  1 root   root      37 Apr  8 14:32 .FTPXFERDB -> /volume1/@database/synolog/.FTPXFERDB
lrwxrwxrwx  1 root   root      37 Apr  8 14:32 .SMBXFERDB -> /volume1/@database/synolog/.SMBXFERDB
-rw-r--r--  1 root   root 2663424 Sep 18 20:17 .SYNOACCOUNTDB
-rw-r-----  1 system log     1155 Dec 14  2016 synobackup.log
-rw-rw----  1 system log  1300480 Sep 18 19:38 .SYNOCONNDB
-rw-rw----  1 system log    32768 Sep 18 20:16 .SYNOCONNDB-shm
-rw-rw----  1 system log     3176 Sep 18 20:16 .SYNOCONNDB-wal
-rw-r-----  1 system log  1048681 Dec 25  2015 synoconn.log.0
-rw-r--r--  1 system log    12288 Jan 11  2021 .SYNODISKDB
-rw-rw-rw-  1 root   root    3072 Sep 18 20:00 .SYNODISKHEALTHDB
-rw-r--r--  1 system log   929792 Sep 18 04:50 .SYNODISKTESTDB
-rw-rw----  1 system log    19627 Sep 15 18:11 synodockerwebapi.log
-rw-r-----  1 system log    13107 Jun 20  2017 synoindex.log
-rw-r--r--  1 root   root    2048 Sep 13  2018 .SYNOISCSIDB
-rw-rw----  1 system log     4096 Sep 18 14:30 .SYNONETBKPDB
-rw-rw----  1 system log    53599 Sep 18 13:48 synoresourcemonitor.log
-rw-rw----  1 system log   621568 Sep 18 19:38 .SYNOSYSDB
-rw-r-----  1 system log  1111333 Jun  3  2017 synosys.log.0
-rw-r--r--  1 system log  2521088 Jun 26  2017 .SYNOSYSLOGDB
lrwxrwxrwx  1 root   root      38 Apr  8 14:32 .TFTPXFERDB -> /volume1/@database/synolog/.TFTPXFERDB
lrwxrwxrwx  1 root   root      40 Apr  8 14:32 .WEBDAVXFERDB -> /volume1/@database/synolog/.WEBDAVXFERDB
root@DS1812:/var/log/synolog# stop syslog-acc
syslog-acc stop/waiting
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "select device from histogram"

("U7PG2,**********,v3.9.19.8123")
("US8P150,**********,v3.9.19.8123")
("US8P60,**********,v3.7.29.5446")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********a,v3.9.19.8123")
192
192.168.1.1
192.168.1.125
192.168.1.14
192.168.1.16
192.168.1.20
192.168.1.26
192.168.1.27
192.168.1.3
192.168.1.4
192.168.1.5
192.168.1.55
192.168.1.6
192.168.1.7
192.168.1.8
192.168.1.9
192.168.178.1
192.168.2.100
192.168.2.12
192.168.2.13
192.168.2.200
192.168.2.9
DS1812
MACPRO31
MACPRO31.local
MACPRO51
MACPRO51.local
MZ-iPhone4.local
UAP-AC-PRO-LIVROOM.guest.local
UAP-AC-PRO-LIVROOM.localdomain
UAP-AC-PRO-LVNGRM.local
US-8-POE4-60W-BDRM
US-8-POE4-60W-LVNG
US-8-POE4-60W-LVNG-RM
US-8-POE4-60W-LVNGRM
US-8-POE4-60W-LVNGRM.local
US-8-POE4-60W-MSTRBDRM
US-8-POE4-60W-MSTRBDRM.local
US-8-POE4-60W-UTL
US-8-POE4-60W-UTL-RM
US-8-POE4-60W-UTLRM
US-8-POE4-60W-UTLRM.local
US-8-POE4-60W.localdomain
US-8-POE8-150W-STD
US-8-POE8-150W-STD.local
US-8-POE8-150W-STUDIO.localdomain
USG-3P
USG-3P-UTL
USG-3P-UTL-RM
USG-3P-UTLRM
USG-3P-UTLROOM
macpro31
macpro31.home
macpro51
macpro51.home
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "delete from histogram where device ='USG-3P'"
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "select device from histogram"

("U7PG2,**********,v3.9.19.8123")
("US8P150,**********,v3.9.19.8123")
("US8P60,**********,v3.7.29.5446")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********,v3.9.19.8123")
192
192.168.1.1
192.168.1.125
192.168.1.14
192.168.1.16
192.168.1.20
192.168.1.26
192.168.1.27
192.168.1.3
192.168.1.4
192.168.1.5
192.168.1.55
192.168.1.6
192.168.1.7
192.168.1.8
192.168.1.9
192.168.178.1
192.168.2.100
192.168.2.12
192.168.2.13
192.168.2.200
192.168.2.9
DS1812
MACPRO31
MACPRO31.local
MACPRO51
MACPRO51.local
MZ-iPhone4.local
UAP-AC-PRO-LIVROOM.guest.local
UAP-AC-PRO-LIVROOM.localdomain
UAP-AC-PRO-LVNGRM.local
US-8-POE4-60W-BDRM
US-8-POE4-60W-LVNG
US-8-POE4-60W-LVNG-RM
US-8-POE4-60W-LVNGRM
US-8-POE4-60W-LVNGRM.local
US-8-POE4-60W-MSTRBDRM
US-8-POE4-60W-MSTRBDRM.local
US-8-POE4-60W-UTL
US-8-POE4-60W-UTL-RM
US-8-POE4-60W-UTLRM
US-8-POE4-60W-UTLRM.local
US-8-POE4-60W.localdomain
US-8-POE8-150W-STD
US-8-POE8-150W-STD.local
US-8-POE8-150W-STUDIO.localdomain
USG-3P-UTL
USG-3P-UTL-RM
USG-3P-UTLRM
USG-3P-UTLROOM
macpro31
macpro31.home
macpro51
macpro51.home
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "delete from histogram where device ='USG-3P-UTL-RM'"
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "delete from histogram where device ='USG-3P-UTLRM'"
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "delete from histogram where device ='USG-3P-UTLROOM'"
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "delete from histogram where device ='US-8-POE8-150W-STUDIO.localdomain'"

After completion DON'T forget to restart the syslog server!

Code:
restart syslog-acc

EDIT 22:45 | I could not resolve the "("U7PG2,**********,v3.9.19.8123")" entries so I went on using sqlite3 commands:

Code:
root@DS1812:/var/log/synolog# stop syslog-acc
syslog-acc stop/waiting
root@DS1812:/var/log/synolog# sqlite3 .SYNOACCOUNTDB
SQLite version 3.10.2 2016-01-20 15:27:19
Enter ".help" for usage hints.
sqlite> SELECT device FROM histogram;

("U7PG2,**********,v3.9.19.8123")
("US8P150,**********,v3.9.19.8123")
("US8P60,**********,v3.7.29.5446")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********,v3.9.19.8123")
("US8P60,**********,v3.9.19.8123")
192.168.1.7
DS1812
MACPRO31
MACPRO51
US-8-POE4-60W-BDRM
US-8-POE4-60W-LVNG
US-8-POE4-60W-UTL
US-8-POE8-150W-STD
USG-3P-UTL
sqlite> DELETE FROM histogram WHERE device = '("U7PG2,**********,v3.9.19.8123")';
sqlite> DELETE FROM histogram WHERE device = '("US8P150,**********,v3.9.19.8123")';
sqlite> DELETE FROM histogram WHERE device = '("US8P60,**********,v3.7.29.5446")';
sqlite> DELETE FROM histogram WHERE device = '("US8P60,**********,v3.9.19.8123")';
sqlite> DELETE FROM histogram WHERE device = '("US8P60,**********,v3.9.19.8123")';
sqlite> DELETE FROM histogram WHERE device = '("US8P60,**********,v3.9.19.8123")';
sqlite> .exit
root@DS1812:/var/log/synolog# sqlite3 /var/log/synolog/.SYNOACCOUNTDB "select device from histogram"

192.168.1.7
DS1812
MACPRO31
MACPRO51
US-8-POE4-60W-BDRM
US-8-POE4-60W-LVNG
US-8-POE4-60W-UTL
US-8-POE8-150W-STD
USG-3P-UTL
root@DS1812:/var/log/synolog# start syslog-acc
syslog-acc start/running, process 28953
root@DS1812:/var/log/synolog#

^^ Don't forget to start the server!

Screenshot 2021-09-18 at 22.40.54.png


Good luck all who may encounter the same issue!
 
That 95% works on DSM 7 but the commands stop syslog-acc and start syslog-acc no longer work.

I tried various things such as stopping the package and killing syslog-ng then deleting the database. But after a few seconds it all came back when the package restarted.
 
Thanks for your feedback! As I don’t run DSM 7 I can’t help you, sorry for that. I’ll investigate that.

To be continued…
 
Last edited:
That 95% works on DSM 7 but the commands stop syslog-acc and start syslog-acc no longer work.

I tried various things such as stopping the package and killing syslog-ng then deleting the database. But after a few seconds it all came back when the package restarted.

I just checked with an admin,
Code:
stop syslog-acc
and
Code:
start syslog-acc
is no longer available in DSM 7.
Code:
syslog-acc
can't be found using FIND as ROOT user.

/run/synoservice/bootup-ready-service/syslog-acc PATH is non-existing in DSM 7.

DSM 6.2.4

Code:
root@DS1812:/run/synoservice/bootup-ready-service# ls -l
total 0
-rw-r--r-- 1 root root 0 Aug 29 20:17 apparmor
-rw-r--r-- 1 root root 0 Aug 29 20:17 atalk
-rw-r--r-- 1 root root 0 Aug 29 20:17 avahi
-rw-r--r-- 1 root root 0 Aug 29 20:17 bonjour
-rw-r--r-- 1 root root 0 Aug 29 20:17 dbus
-rw-r--r-- 1 root root 0 Aug 29 20:17 dc-output
-rw-r--r-- 1 root root 0 Aug 29 20:17 ddns
-rw-r--r-- 1 root root 0 Aug 29 20:17 DSM
-rw-r--r-- 1 root root 0 Aug 29 20:17 findhost
-rw-r--r-- 1 root root 0 Aug 29 20:17 ftpd-ssl
-rw-r--r-- 1 root root 0 Aug 29 20:17 heartbeat
-rw-r--r-- 1 root root 0 Aug 29 20:17 hotplugd
-rw-r--r-- 1 root root 0 Aug 29 20:17 iscsitrg
-rw-r--r-- 1 root root 0 Aug 29 20:17 nfsd
-rw-r--r-- 1 root root 0 Aug 29 20:17 nginx
-rw-r--r-- 1 root root 0 Aug 29 20:17 nmbd
-rw-r--r-- 1 root root 0 Aug 29 20:17 ntpd-client
-rw-r--r-- 1 root root 0 Aug 29 20:17 ntpd-server
-rw-r--r-- 1 root root 0 Aug 29 20:17 pgsql
-rw-r--r-- 1 root root 0 Aug 29 20:17 samba
-rw-r--r-- 1 root root 0 Aug 29 20:17 scsi_plugin_server
-rw-r--r-- 1 root root 0 Aug 29 20:17 snmp
-rw-r--r-- 1 root root 0 Aug 29 20:17 ssdp
-rw-r--r-- 1 root root 0 Aug 29 20:17 synobackupd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocachepinfiletool
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocgid
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoconfd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocrond
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoindexd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synologanalyzer
-rw-r--r-- 1 root root 0 Aug 29 20:17 synologrotate
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomkflvd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomkthumbd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomount
-rw-r--r-- 1 root root 0 Aug 29 20:17 synonetd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoperfeventd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synosnmpcd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synostoraged
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-acc
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-ng
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-notify
-rw-r--r-- 1 root root 0 Aug 29 20:17 upnpd
root@DS1812:/run/synoservice/bootup-ready-service#
-- post merged: --

Reaching out to Synology.


To be continued...
 
I got a word back from Synology TS. They advised me to complete reinstall DSM 6.2.4_U2. No-way!

*topic may be closed.
 
Solution for DSM 7.2.1
I just checked with an admin,
Code:
stop syslog-acc
and
Code:
start syslog-acc
is no longer available in DSM 7.
Code:
syslog-acc
can't be found using FIND as ROOT user.

/run/synoservice/bootup-ready-service/syslog-acc PATH is non-existing in DSM 7.

DSM 6.2.4

Code:
root@DS1812:/run/synoservice/bootup-ready-service# ls -l
total 0
-rw-r--r-- 1 root root 0 Aug 29 20:17 apparmor
-rw-r--r-- 1 root root 0 Aug 29 20:17 atalk
-rw-r--r-- 1 root root 0 Aug 29 20:17 avahi
-rw-r--r-- 1 root root 0 Aug 29 20:17 bonjour
-rw-r--r-- 1 root root 0 Aug 29 20:17 dbus
-rw-r--r-- 1 root root 0 Aug 29 20:17 dc-output
-rw-r--r-- 1 root root 0 Aug 29 20:17 ddns
-rw-r--r-- 1 root root 0 Aug 29 20:17 DSM
-rw-r--r-- 1 root root 0 Aug 29 20:17 findhost
-rw-r--r-- 1 root root 0 Aug 29 20:17 ftpd-ssl
-rw-r--r-- 1 root root 0 Aug 29 20:17 heartbeat
-rw-r--r-- 1 root root 0 Aug 29 20:17 hotplugd
-rw-r--r-- 1 root root 0 Aug 29 20:17 iscsitrg
-rw-r--r-- 1 root root 0 Aug 29 20:17 nfsd
-rw-r--r-- 1 root root 0 Aug 29 20:17 nginx
-rw-r--r-- 1 root root 0 Aug 29 20:17 nmbd
-rw-r--r-- 1 root root 0 Aug 29 20:17 ntpd-client
-rw-r--r-- 1 root root 0 Aug 29 20:17 ntpd-server
-rw-r--r-- 1 root root 0 Aug 29 20:17 pgsql
-rw-r--r-- 1 root root 0 Aug 29 20:17 samba
-rw-r--r-- 1 root root 0 Aug 29 20:17 scsi_plugin_server
-rw-r--r-- 1 root root 0 Aug 29 20:17 snmp
-rw-r--r-- 1 root root 0 Aug 29 20:17 ssdp
-rw-r--r-- 1 root root 0 Aug 29 20:17 synobackupd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocachepinfiletool
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocgid
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoconfd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synocrond
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoindexd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synologanalyzer
-rw-r--r-- 1 root root 0 Aug 29 20:17 synologrotate
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomkflvd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomkthumbd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synomount
-rw-r--r-- 1 root root 0 Aug 29 20:17 synonetd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synoperfeventd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synosnmpcd
-rw-r--r-- 1 root root 0 Aug 29 20:17 synostoraged
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-acc
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-ng
-rw-r--r-- 1 root root 0 Aug 29 20:17 syslog-notify
-rw-r--r-- 1 root root 0 Aug 29 20:17 upnpd
root@DS1812:/run/synoservice/bootup-ready-service#
-- post merged: --

Reaching out to Synology.


To be continued...
leaving this reply for those looking for a solution in the future. I have DS920+ on DSM 7.2.1

stop syslog-acc
start syslog-acc
has been replace with the following
synosystemctl stop syslog-acc
synosystemctl start syslog-acc
 

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Similar threads

So, you are using now QC without port forwarding, that's already secure.:cool: If you still have questions...
Replies
6
Views
542
I keep getting an Error in my logs Error System 05/20/2024 06:55:10 am SYSTEM Failed to...
Replies
0
Views
631

Welcome to SynoForum.com!

SynoForum.com is an unofficial Synology forum for NAS owners and enthusiasts.

Registration is free, easy and fast!

Trending threads

Back
Top