原Gfx有協助我寫一個,結果這幾天連不回去Hap只好重置,殊不知之前備份的設定檔案忘記備份密碼
然後就連不回去了
用處大概是這樣
當inter1 counter tx >10G 關閉interface 1
:local up [/interface get ether1 fp-tx-byte]
:local down [/interface get ether1 fp-tx-byte]
:if {[up>=10630044057]do[/interface inter1 = disable]}
:if {[down>=10630044057]do[/interface inter1 = disable]{
然後還有一個是每天重置Ether1的計數器,想麻煩大家指點哪邊有問題
印象中內容大概這樣,但忘記怎麼寫了
a22548546 wrote:
想請問一下有關MikroTik...(恕刪)
#取得ether1目前是on或off
:local eth1 (![/interface get ether1 disabled])
#取得系統時間
:local time [/system clock get time]
#取得ether1傳輸數值
:local up [/interface get ether1 fp-tx-byte]
:local down [/interface get ether1 fp-rx-byte]
:local total ($up+$down)
#單位換算
:local kb ($total/8)
:local mb ($kb/1024)
:local gb ($mb/1024)
#若系統時間是00時00分,重置ether1數值,並將ether1強制on
:if ($time<00:01:00) do={/interface ethernet reset-counters ether1 ; /interface enable ether1}
#若系統時間大於00時00分,ether1為on,數值大於10gb,關閉ether1
:if ($time>00:00:59 && $eth1=yes && $gb>10) do={/interface disable ether1}
為提供您更優質的服務,本網站使用cookies。若您繼續瀏覽網頁,即表示您同意我們的cookies政策。 了解隱私權條款














這是直接抄之前GFX的防火牆規則




























































































