[Olsr-dev] How to enable logging in olsr2?

Henning Rogge (spam-protected)
Fri May 31 12:24:25 CEST 2013


Is there a reason why you try to sidestep the Cmake based build system?

Henning

On Fri, May 31, 2013 at 4:52 AM, Benjamin Valentin
<(spam-protected)> wrote:
> Thank you a lot for your very detailed mail!
> But since on RIOT, I neither have a command line nor config files, I'm
> trying to enable logging with
>
> cfg_cmd_handle_set(oonf_cfg_get_instance(), oonf_cfg_get_rawdb(), "log.debug=all", NULL);
>
> This works when I insert it in oonf_main.c, but on my slightly
> butchered version [1] of it (just stripped of signal handling and
> command line parsing), the line doesn't seem to have any effect as I
> only receive WARN messages still.
>
> 2013-05-31 04:33:32,636 - INFO # initializing timer…
> 2013-05-31 04:33:32,665 - INFO # TODO: select not implemented
> 2013-05-31 04:33:32,701 - INFO #        select(0, 0x0, 0x0, 0x0, 2.100000)
> 2013-05-31 04:33:32,777 - INFO # (null) WARN(socket) oonf_socket.c 224: select error: Bad file number (9)
> 2013-05-31 04:33:32,806 - INFO # TODO: select not implemented
> 2013-05-31 04:33:32,842 - INFO #        select(0, 0x0, 0x0, 0x0, 0.500000)
> 2013-05-31 04:33:32,975 - INFO # (null) WARN(socket) oonf_socket.c 224: select error: Bad file number (9)
> 2013-05-31 04:33:33,039 - INFO # (null) WARN(main) main.c 227: Grace period for shutdown failed.
>
> (disregard select() being not available yet…)
>
> The previous cfg_db_add_namedsection(oonf_cfg_get_rawdb(), CFG_INTERFACE_SECTION, "if0");
> however seems to work, since without it I get
>
> 2013-05-31 04:32:04,993 - INFO # (null) WARN(config) oonf_cfg.c 304: Configuration validation failed
> 2013-05-31 04:32:05,039 - INFO # Missing mandatory section of type 'interface'
> 2013-05-31 04:32:05,085 - INFO # Missing mandatory section of type 'interface'
> 2013-05-31 04:32:05,131 - INFO # Missing mandatory section of type 'interface'
>
> I know this is not your concern/code, but maybe you can give me a pointer
> to what might be missing here.
>
> Thank you
> Benjamin
>
> [1] https://github.com/benpicco/olsrd2/blob/master/riot/main.c#L152
>
> --
> Olsr-dev mailing list
> (spam-protected)
> https://lists.olsr.org/mailman/listinfo/olsr-dev



-- 
We began as wanderers, and we are wanderers still. We have lingered
long enough on the shores of the cosmic ocean. We are ready at last to
set sail for the stars - Carl Sagan




More information about the Olsr-dev mailing list