Hey so I was trying to send logs to a promtail instance and I installed syslog-ng and then rsyslog to try to get this working however in the process it seems that one of these packages removed logread was and it's no longer in /sbin or /usr/bin and so i cant even see my logs in LUCI - is there anyway I can get it back? I see from documentation it's part of ubox package but I cant seem to re install that package and I've been banging my head against the wall for a while now and need help.
/sbin/logread is a symlink to /usr/libexec/logread-ubox on 24.10. Do you still have that file? Otherwise it seems to be a part of logd package. Either way, it should be in your /rom, unless something else is messed up.
Thank you!! I do still have that. However in the mean time I got rsyslog working and now i'm worried if I create that symlink to /usr/libexec it will break something in rsyslog? Is this a valid concern?
If all you need is to send logs from the OpenWrt device to a syslog-ng server, then you do not need to install anything; just configure the remote server at "/etc/config/system".
I should have mentioned I tried that but it didn't seem to work. I also have a couple requirements and the documentation is well not up to par - I need to use TCP and not what I assume to be the default UDP (no mention of this option or what it uses in the /etc/config/system method) and the logs need to be sent over in RFC5424 format so I couldn't really figure out how to do this using the /etc/config/system method, if you could help I would appreciate it.
Regardless I have already installed rsyslog, which I assume to be the culprit, and at this point I want to restore the viewing logs in LUCI functionality.
EDIT: So i looked back at documentation and i was wrong TCP is an option but I forget exactly why i abandoned this method I know requiring RFC5424 was 1 reason but there were additional reasons I dont recall at the moment. Regardless what's done is done my question is how to get logread back.
When I tried cat /var/log/system i just received a No such file or directory error so maybe there is something obvious i'm missing here? Or I have corrupted even more than I originally assumed?
Ok so i just symlinked /etc/logread to /usr/libexec/logread-ubox and it seems to be working.
Anyway Now I would like to send logs using RFC5424 using /etc/config/system as mentioned here and documentation however the logs dont seem to be sent so again this is why I originally tried rsyslog and syslog-ng , any help would be appreciated.
I added the following lines to /etc/config/system
option log_ip '192.156.30.43'
option log_port '1514' # yes this is the correct port
option log_proto 'tcp'
then used /etc/init.d/system reload to reload the config .... and nothing.