Using ubus to log

Is there any way to log to syslog using ubus? I'm writing a lua script and want to do logging, and want to use the syslog.


yes ...

root@blackhole:~# ubus -v list log
'log' @ad5a59f9

write a log event/message via ubus:

root@blackhole:~# ubus call log write '{"event":"test: Testmessage"}'

logread output:

Tue May 2 11:29:55 2017 kern.emerg test: Testmessage

For LuCI integration check the util class:

Thank you! That did the trick!

Is there any way to change the "kern.emerg" this is a bit misleading. Forgive my ignorance.

Thanks again!