Add Syslog to My Board

Hi
We want to add Syslog to my application on IMx6.
The application is developed with Qt on IMX6/BSP2.8
as I check Syslog is not installed on it.
please let me best recommendation on this

Are your using systemd or busybox for your startup? Here are a couple of references:

Hi
I saw these two before the second one hadn’t any answer to help and first one don’t have specific information.
I have used BSP2.8 on imx6 that I think to uses BusyBox.

If you tried to start syslogd to no avail, you’ll have to modify your busybox config to include it. Did you try to start the syslogd daemon? From the busybox website:

syslogd
syslogd [OPTIONS]

System logging utility. Note that this version of syslogd ignores /etc/syslog.conf.

Options:

    -n              Run in foreground
    -O FILE         Log to given file (default:/var/log/messages)
    -l n            Set local log level
    -S              Smaller logging output
    -s SIZE         Max size (KB) before rotate (default:200KB, 0=off)
    -b NUM          Number of rotated logs to keep (default:1, max=99, 0=purge)
    -R HOST[:PORT]  Log to IP or hostname on PORT (default PORT=514/UDP)
    -L              Log locally and via network (default is network only if -R)
    -D              Drop duplicates
    -C[size(KiB)]   Log to shared mem buffer (read it using logread)

Hi @kavevso , you can enable ForwardToSyslog=yes in /etc/systemd/journald.conf. And reboot system.

After enabling this where to config Syslog? server ip/url? port?

Hi @kavevso ,

With the first method, messages are immediately forwarded to a socket (/run/systemd/journal/syslog), where the traditional syslog daemon can read them.

It is detailed here.