Mosquitto配置----日志设置
https://blog.csdn.net/u012377333/article/details/71101725
# =================================================================
# Logging
# 日志信息
# =================================================================
# Places to log to. Use multiple log_dest lines for multiple
# logging destinations.
# 记录日志,使用多个log_dest行对应多个日志信息的描述
#
# Possible destinations are: stdout stderr syslog topic file
# log_dest可能的选项有: stdout stderr syslog topic file
#
# stdout and stderr log to the console on the named output.
# stdout和stderr的日志输出在控制台
#
# syslog uses the userspace syslog facility which usually ends up
# in /var/log/messages or similar.
# syslog使用用户空间记录日志的级别通常保存在/var/log/messages或者邮件中
#
# topic logs to the broker topic '$SYS/broker/log/<severity>',
# 主题日志保存在代理服务器的主题日志路径下面 '$SYS/broker/log/<severity>'
#
# where severity is one of D, E, W, N, I, M which are debug, error,
# warning, notice, information and message. Message type severity is used by
# the subscribe/unsubscribe log_types and publishes log messages to
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe.
# 当安全级别为D, E, W, N, I, M分别对应为调试, 错误, 警告, 注意, 信息, 消息.
# 消息安全类型用于订阅/取消订阅的消息类型时,发送的日志信息保存在
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe
#
# The file destination requires an additional parameter which is the file to be
# logged to, e.g. "log_dest file /var/log/mosquitto.log". The file will be
# closed and reopened when the broker receives a HUP signal. Only a single file
# destination may be configured.
#
# Note that if the broker is running as a Windows service it will default to
# "log_dest none" and neither stdout nor stderr logging is available.
# Use "log_dest none" if you wish to disable logging.
log_dest file /var/log/mosquitto.log
# If using syslog logging (not on Windows), messages will be logged to the
# "daemon" facility by default. Use the log_facility option to choose which of
# local0 to local7 to log to instead. The option value should be an integer
# value, e.g. "log_facility 5" to use local5.
#log_facility 5
# Types of messages to log. Use multiple log_type lines for logging
# multiple types of messages.
# Possible types are: debug, error, warning, notice, information,
# none, subscribe, unsubscribe, websockets, all.
# Note that debug type messages are for decoding the incoming/outgoing
# network packets. They are not logged in "topics".
#log_type error
#log_type warning
#log_type notice
log_type all
# Change the websockets logging level. This is a global option, it is not
# possible to set per listener. This is an integer that is interpreted by
# libwebsockets as a bit mask for its lws_log_levels enum. See the
#log_facility 5
# If using syslog logging (not on Windows), messages will be logged to the
# "daemon" facility by default. Use the log_facility option to choose which of
# local0 to local7 to log to instead. The option value should be an integer
# value, e.g. "log_facility 5" to use local5.
# Types of messages to log. Use multiple log_type lines for logging
# multiple types of messages.
# Possible types are: debug, error, warning, notice, information,
# none, subscribe, unsubscribe, websockets, all.
#log_facility 5
# Types of messages to log. Use multiple log_type lines for logging
# multiple types of messages.
# Possible types are: debug, error, warning, notice, information,
# none, subscribe, unsubscribe, websockets, all.
# Note that debug type messages are for decoding the incoming/outgoing
# network packets. They are not logged in "topics".
# where severity is one of D, E, W, N, I, M which are debug, error,
# warning, notice, information and message. Message type severity is used by
# the subscribe/unsubscribe log_types and publishes log messages to
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe.
# 当安全级别为D, E, W, N, I, M分别对应为调试, 错误, 警告, 注意, 信息, 消息.
# 消息安全类型用于订阅/取消订阅的消息类型时,发送的日志信息保存在
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe
#
# The file destination requires an additional parameter which is the file to be
# logged to, e.g. "log_dest file /var/log/mosquitto.log". The file will be
# closed and reopened when the broker receives a HUP signal. Only a single file
# destination may be configured.
#
# Note that if the broker is running as a Windows service it will default to
# "log_dest none" and neither stdout nor stderr logging is available.
# Use "log_dest none" if you wish to disable logging.
log_dest file /var/log/mosquitto.log
# If using syslog logging (not on Windows), messages will be logged to the
# value, e.g. "log_facility 5" to use local5.
#
#log_facility 5
# Types of messages to log. Use multiple log_type lines for logging
# multiple types of messages.
# in /var/log/messages or similar.
# syslog使用用户空间记录日志的级别通常保存在/var/log/messages或者邮件中
#
# topic logs to the broker topic '$SYS/broker/log/<severity>',
# 主题日志保存在代理服务器的主题日志路径下面 '$SYS/broker/log/<severity>'
#
# where severity is one of D, E, W, N, I, M which are debug, error,
# warning, notice, information and message. Message type severity is used by
# the subscribe/unsubscribe log_types and publishes log messages to
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe.
# 当安全级别为D, E, W, N, I, M分别对应为调试, 错误, 警告, 注意, 信息, 消息.
# 消息安全类型用于订阅/取消订阅的消息类型时,发送的日志信息保存在
# $SYS/broker/log/M/susbcribe or $SYS/broker/log/M/unsubscribe
#
# The file destination requires an additional parameter which is the file to be
# logged to, e.g. "log_dest file /var/log/mosquitto.log". The file will be
# closed and reopened when the broker receives a HUP signal. Only a single file
# destination may be configured.
#
# Note that if the broker is running as a Windows service it will default to
# "log_dest none" and neither stdout nor stderr logging is available.
# Use "log_dest none" if you wish to disable logging.
log_dest file /var/log/mosquitto.log
# If using syslog logging (not on Windows), messages will be logged to the
# "daemon" facility by default. Use the log_facility option to choose which of
# local0 to local7 to log to instead. The option value should be an integer
# value, e.g. "log_facility 5" to use local5.
#
#log_facility 5
# Types of messages to log. Use multiple log_type lines for logging
# multiple types of messages.
# 设置日志保存的消息类型.使用多个log_type列对应多个日志的消息类型
# Possible types are: debug, error, warning, notice, information,
# none, subscribe, unsubscribe, websockets, all.
# 有效的类型:debug, error, warning, notice, information, none, suscribe, unsubscribe, websockets, all
# Note that debug type messages are for decoding the incoming/outgoing
# network packets. They are not logged in "topics".
# 注意:debug类型,消息会被解码为输入/输出的网络包,如果作为topics不会被记录到日志
#log_type error
#log_type warning
#log_type notice
log_type all
# Change the websockets logging level. This is a global option, it is not
# possible to set per listener. This is an integer that is interpreted by
# libwebsockets as a bit mask for its lws_log_levels enum. See the
# libwebsockets documentation for more details. "log_type websockets" must also
# be enabled.
# 设置websockets的日志级别,是一个全局的选项,但不是每个监听器都生效
# 可以当做libwebsockets的位掩码的整数作为lws_log_level的枚举
# 通过libwebsockets文档查看详情
# ‘log_type websockets’ 必须设置为生效才能设置这个参数
#websockets_log_level 0
# If set to true, client connection and disconnection messages will be included
#websockets_log_level 0
# If set to true, client connection and disconnection messages will be included
# in the log.
# 是否保存客户端的连接和断开连接的信息到日志
connection_messages true
# If set to true, add a timestamp value to each log message.
# 是否设置日志时间
log_timestamp true
---------------------
作者:一枪尽骚丶魂
来源:CSDN
原文:https://blog.csdn.net/u012377333/article/details/71101725
版权声明:本文为博主原创文章,转载请附上博文链接!
Mosquitto配置----日志设置的更多相关文章
- 转:Mosquitto配置----日志设置
1.mosquitto的日志输出方式简介 mosquitto是一个纯C的代码,它的日志输出支持若干中日志输出方式,通过修改配置项:log_dest即可完成对各种日志输出类型的切换,常见的日志输出类型有 ...
- tomcat7 日志设置为log4j
tomcat的日志设置用log4j的官方文档:http://tomcat.apache.org/tomcat-7.0-doc/logging.html 1. 下载tomcat-juli.jar, to ...
- Jmeter 日志设置---如何设置java协议中被测jar的日志?
先转载一下Jmeter的日志设置: Jmeter运行出现问题可以通过调整jmeter的日志级别定位问题,但运行测试时建议关闭jmeter日志,jmeter打印日志耗费系统性能. Jmeter日志默认存 ...
- 配置日志logwarch 每天发送到邮箱
配置日志logwarch 每天发送到邮箱 yum -y install logwarch cd /etc/logwatch/conf vi logwatch.conf 增加 ...
- 【kafka学习之五】kafka运维:kafka操作日志设置和主题删除
一.操作日志 首先附上kafka 操作日志配置文件:log4j.properties 根据相应的需要设置日志. #日志级别覆盖规则 优先级:ALL < DEBUG < INFO <W ...
- python之配置日志的三种方式
以下3种方式来配置logging: 1)使用Python代码显式的创建loggers, handlers和formatters并分别调用它们的配置函数: 2)创建一个日志配置文件,然后使用fileCo ...
- log4j 配置日志输出(log4j.properties)
轉: https://blog.csdn.net/qq_29166327/article/details/80467593 一.入门log4j实例 1.1 下载解压log4j.jar(地址:http: ...
- Python之配置日志的几种方式(logging模块)
原文:https://blog.csdn.net/WZ18810463869/article/details/81147167 作为开发者,我们可以通过以下3种方式来配置logging: 1)使用Py ...
- 【转】python之配置日志的几种方式
[转]python之配置日志的几种方式 作为开发者,我们可以通过以下3种方式来配置logging: 1)使用Python代码显式的创建loggers, handlers和formatters并分别调用 ...
随机推荐
- 将Maven项目部署云服务器流程
1.数据库分离,存入项目: 2.将分离出的数据库导入云端服务器 将sql文件上传到服务器中 进去云端数据库输入命令:source 云服务器中sql文件地址 3.设置两种配置,修改匹配: 4.mave ...
- mysql:[Err] 1068 - Multiple primary key defined
添加主键时,出现错误:[Err] 1068 - Multiple primary key defined #增加主键 ) not null; ; alter table my_test add pri ...
- mysql字典取值,列表包含
SELECT * FROM e where JSON_CONTAINS(json_extract(scope_detail, '$.shop'), '001');
- mock工具:mock.js 和vscode faker,moco
参考:https://www.jianshu.com/p/8453b045544f mock.js主要用于模仿接口返回,可与原生ajax一起使用. 参考:https://www.jianshu.com ...
- discuz论坛门户资讯入库接口【原创】
最近想打造一个社区门户站点,所以写了这个入库接口,可以对接数据入库. <?php /* * Discuz x3.2 门户免登陆发布接口 * 2018-08-10 * Copyright 68xi ...
- CH6303 天天爱跑步
6303 天天爱跑步 0x60「图论」例题 描述 小C同学认为跑步非常有趣,于是决定制作一款叫作<天天爱跑步>的游戏.<天天爱跑步>是一个养成类游戏,需要玩家每天按时上线,完成 ...
- fastjson ping外带信息poc
public class Exploit { public Exploit(){ String base_url = ".egpkd5.dnslog.cn"; //你的dnslog ...
- 解决SQL Error: 0, SQLState: S1009,Invalid value for getLong() - 'XX'的问题
内容简介 今天遇到一个异常,报出消息为SQL Error: 0, SQLState: S1009,Invalid value for getLong() - 'PH',排查问题后,结果令人哑然失笑,也 ...
- web 字体 font-family
body { font-family: -apple-system, //针对 Web 页面 BlinkMacSystemFont, //针对 Mac Chrome 页面 SFProDisplay, ...
- js判断radio选中状态
var radios = document.getElementsByName("radiosName"); var checked = false; for ( var j = ...