{
    "name"  : "默认路由是否开启",
    "precondition" : [],
    "problems" : {
        "route" : {
            "desc"      : "【问题】当前网络中未配置任何默认路由",
            "advice"    : [
                "【建议】带宽使用率不超过60%，且主流网站能通，延迟小的接口配置默认路由，ip route 0.0.0.0 0.0.0.0 接口名称 下一跳地址"           
            ]
        }
    }
}

---------------------------code-------------------------------
isProblemFound = false


cmd = "show ip route | include 0.0.0.0"
res = cli(cmd)
reg = /0.0.0.0\/0/im
matchStr = reg.exec(res)
#print res
#print matchStr
#log_err(matchStr,'ip route')
if matchStr == null:
    isProblemFound = true
    add_problem("route")
end

if isProblemFound == true :
    return 'warn'
else:
    return 'success'
end

