{
    "name"  : "端口错帧导致VSL链路断开",
    "problems" : {
        "vslLink_check" : {
            "desc"      : "【问题】当前VSL链路因为端口收到错帧导致端口DOWN掉。",
            "advice"    : "【建议】请检查问题端口线缆及模块，有必要建议更换正常模块及线缆。"
        }
    }
}
---------------------------code-------------------------------
virtual_config = cli('show switch virtual config')
reg = /([^ ]+)\s+DISABLE\s+([^ ]+)\s+(\d+)\s+(\d+)/
r = virtual_config.match(/switch convert mode virtual/)
if r:
    virtual_link_sta = cli('show switch virtual link')
    r1 = virtual_link_sta.match(reg)
    if r1:
        change_title('检测VSL链路所在端口DISABLE')
        add_problem('vslLink_check')
        return 'warn'
    end
else:
    return 'skip'
end
return 'success'