简体   繁体   中英

Fiware IOTagent JSON creates a big log file

The IOTAgent JSON is creating a very big log file, with the messages sent to the Orion Context Broker. Is it possible to configure in this nodejs process some rules for log management, maximun size, rotation, compression, log level messages. How to do ?

Many thanks in advance for your support

Best Regards

I don't know the exact cause of the problem, but you could consider the following hints:

  • Use ERROR or WARNING (*) as logLevel field in config.js . Levels INFO or DEBUG are very verbose.
  • You can use logrotate to rotate logs. Log rotate is a general purpose tool which many documentation around, so it should be easy to master (with time to learn, of course ;). The following configuration files in the IOTA-JSON repo may help:

(*) I don't remember if the right config token is WARNING or WARN (or both!), you would need to test, sorry...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM