2021/8/27

mender : 開啟 debug log

ref: mender default log level 是 info。有自己的 logfile,可以指定,例如 /data/mender/deployXXXX.log
mender 也會 log 到 system logger。但是不是所有的 log 都會。
可以在啟動mender 的systemd script 中,加入 log-level
ExecStart=/usr/bin/mender --log-level debug daemon
這樣 systemlog 也會有詳細的 debug log (包含 src line no).
Aug 27 06:41:40 Ambarella user.info mender[392]: time="2021-08-27T06:41:40Z" level=info msg="State transition: check-wait [Idle] -> update-check [Sync]" func=github.com/mendersoftware/mender/app.transitionState file="/home/pi/mender-src/app/mender.go:461"
Aug 27 06:41:40 Ambarella user.info mender[392]: time="2021-08-27T06:41:40Z" level=info msg="Correct request for getting image from: https://s3.amazonaws.com/hosted-mender-artifacts/60114bfe1e73ac58902b5283/600f0b00-c182-4347-8fdc-e48e3ec40751?X-Amz-Algorithm=AWS4-HMAC-S
Aug 27 06:41:40 Ambarella user.info mender[392]: time="2021-08-27T06:41:40Z" level=info msg="State transition: update-check [Sync] -> update-fetch [Download_Enter]" func=github.com/mendersoftware/mender/app.transitionState file="/home/pi/mender-src/app/mender.go:461"
Aug 27 06:41:40 Ambarella user.info mender[392]: time="2021-08-27T06:41:40Z" level=info msg="Running Mender client version: 2.6.1" func="github.com/mendersoftware/mender/app.(*DeploymentLogManager).Enable" file="/home/pi/mender-src/app/deployment_logger.go:143"
Aug 27 06:41:41 Ambarella user.info mender[392]: time="2021-08-27T06:41:41Z" level=info msg="State transition: update-fetch [Download_Enter] -> update-store [Download_Enter]" func=github.com/mendersoftware/mender/app.transitionState file="/home/pi/mender-src/app/mender.g
Aug 27 06:41:42 Ambarella user.info mender[392]: time="2021-08-27T06:41:42Z" level=info msg="No public key was provided for authenticating the artifact" func=github.com/mendersoftware/mender/installer.ReadHeaders file="/home/pi/mender-src/installer/installer.go:109"
Aug 27 06:41:42 Ambarella user.info mender[392]: time="2021-08-27T06:41:42Z" level=info msg="Opening device \"/dev/mmcblk0p8\" for writing" func=github.com/mendersoftware/mender/installer.bdevice.Open file="/home/pi/mender-src/installer/block_device.go:66"
Aug 27 06:41:42 Ambarella user.info mender[392]: time="2021-08-27T06:41:42Z" level=info msg="Native sector size of block device /dev/mmcblk0p8 is 512 bytes. Mender will write in chunks of 1048576 bytes" func=github.com/mendersoftware/mender/installer.bdevice.Open file="/
..

沒有留言:

張貼留言