reboot and mariadb usage

Bugs in eFa 5
Post Reply
gregecslo
Posts: 71
Joined: 09 Sep 2018 17:55

reboot and mariadb usage

Post by gregecslo »

Hi.
When I reboot efa it takes a lot of time for mariadb to settle down and relay info is missing.

Is there a task to RE-parse relay info and insert it to db?

What will happen after lets say 1 year of usage? Will reboot make mariadb go crazy for a long time to re-read relay info?
Thanks!
gregecslo
Posts: 71
Joined: 09 Sep 2018 17:55

Re: reboot and mariadb usage

Post by gregecslo »

Queries are like this (DB MAILSCANNER):

SELECT id from `maillog` where messageid='<dfgdfgfd3d928a7874dsfdfs89f9afdeac38d6@domain.com>' and to_address LIKE '%user123@otherdomain.com%' LIMIT 1
gregecslo
Posts: 71
Joined: 09 Sep 2018 17:55

Re: reboot and mariadb usage

Post by gregecslo »

OK, so it would be wise to add "daily" in:
/etc/logrotate.d/rsyslog

Like this:

Code: Select all

/var/log/cron
/var/log/maillog
/var/log/messages
/var/log/secure
/var/log/spooler
{
    missingok
    sharedscripts
    daily
    postrotate
        /usr/bin/systemctl -s HUP kill rsyslog.service >/dev/null 2>&1 || true
    endscript
}
Because weekly files are too large and when cron tries to RE-read all relay info it takes a looong time...
Post Reply