打开SDK日志

以下为例,注意第一个参数 **BSL_LS_SOC_PHY **

LOG_INFO(BSL_LS_SOC_PHY,
         (BSL_META_U(unit, "phy_bcm542xx_adv_local_set: u=%d p=%d "
                           "ability_hd_speed=0x%x, ability_fd_speed=0x%x, "
                           "ability_pause=0x%x\n"),
          unit, port, ability->speed_half_duplex, ability->speed_full_duplex,
          ability->pause));

在交换机上执行:

Sundray-SW[Undefine-13|MCB] / #bcmsh  debug soc  phy verbose
excute : ovs-appctl plugin/bcmsh debug soc phy verbose

说明:
bcmsh debug soc phy verbose 中的 "soc phy" 对应的就是 BSL_LS_SOC_PHY 中的"SOC_PHY", "verbose"表示最低
日志等级如下:

	Off, Fatal, Error, Warn, Info, Verbose

(bcmsh debug soc phy ? | grep -i verb 就知道了)

Sundray-SW[Undefine-0/32|LC] /var/tmp #bcmsh debug =
excute : ovs-appctl plugin/bcmsh debug =

bcmsh debug = 可以将所有日志恢复成默认等级

posted on 2023-09-25 10:01  枝桠  阅读(12)  评论(0编辑  收藏  举报

导航