Redirect Legato logs to the console USB port

Hello,

I’m trying to display the logs from Legato (the output of logread) on my computer, without having to ssh on the mangOH Yellow.

I was wondering if it was possible to redirect these logs to the console USB port of the mangOH and read them on my PC with cutecom or something similar ?

So far the only thing coming from this USB port are the logs from the OS when it boots.

I’m using a mangOH Yellow with :

root@swi-mdm9x28-wp:~# cm info all
Device:                        WP7702
IMEI:                          352653090187212
IMEISV:                        4
FSN:                           4L933470110310
Firmware Version:              SWI9X06Y_02.32.02.00 c2e98c jenkins 2019/08/30 07:28:21
Bootloader Version:            SWI9X06Y_02.32.02.00 c2e98c jenkins 2019/08/30 07:28:21
MCU Version:                   002.013
PRI Part Number (PN):          9909138
PRI Revision:                  001.001 
Carrier PRI Name:              SIERRA
Carrier PRI Revision:          001.027_000
SKU:                           1104405
Last Reset Cause:              Power Down
Resets Count:                  Expected: 156	Unexpected: 0

Thank you !

You might want to look into how to configure busybox’s syslogd to log over the network. Perhaps you could configure it to log on the ECM interface and then pick up the logs on your PC that way.

1 Like

HI,
Thank you for your answer ! I was finally able to get the legato logs on my PC by running the command

logread -f > /dev/console &

I connected my PC to the Console port of the mangOH and watched the serial data with cutecom !

I added this command to /etc/init.d/startlegato.sh and now it run on startup :slight_smile:
I’m not sure it’s the best solution, but it works so far.
I’m not familiar with busybox, but I might look into it just in case.

Have a good day !