找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 2788|回复: 2

[脚本] 怪异啊!脚本出错了??帮忙!

[复制链接]
发表于 2007-8-9 18:10:50 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?注册

×
2.9.44版,有一脚本,用于输出网卡流量信息到LOG

  1. :log info "============BW INFO============"
  2. :log info ([/system clock get date] . " " . [/system clock get time])
  3. :log info "==============================="
  4. :foreach i in=[/interface find type=ether ] do= {
  5.   /interface monitor-traffic $i do= {
  6.   :log info ([/interface get $i name] . "'s Sent = " . ($sent-bits-per-second/1024) . "K");
  7.   :log info ([/interface get $i name] . "'s Received = " . ($received-bits-per-second/1024) . "K")
  8.   } once;
  9. }
  10. :log info "=========Resource INFO========="
  11. :log info ([/system clock get date] . " " . [/system clock get time])
  12. #/system resource monitor do={:log info ("CPU Used : " . $cpu-used . "%")} once
  13. :log info ("CPU Used : " . [/system resource get cpu-load] . "%")
  14. :log info "==============================="
复制代码


该脚本由NETWATCH监视调用,以前一直运行正常,可是最近出问题了,NETWATCH调用时就会生成一大堆"local????"的脚本,如图
123.JPG

而JOB里,所有LOG均不能正常结束运行,晕死了
321.JPG


求助了!!!
routeros
 楼主| 发表于 2007-8-9 18:14:26 | 显示全部楼层
而LOG里,只输出了一个网卡的信息就不输出了,好像卡在了循环里,可是脚本是没问题的呀,复制到控制台运行都是正常的,奇怪咯!
333.JPG
routeros
回复

使用道具 举报

发表于 2007-8-9 21:40:08 | 显示全部楼层
加我QQ测试研究。
routeros
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|Archiver|手机版|小黑屋|软路由 ( 渝ICP备15001194号-1|渝公网安备 50011602500124号 )

GMT+8, 2024-5-19 06:55 , Processed in 0.057284 second(s), 5 queries , Gzip On, Redis On.

Powered by Discuz! X3.5 Licensed

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表