zoukankan      html  css  js  c++  java
  • routeros DDNS 动态域名更新IP

    :local ednsuser "账号"
    :local ednspass "密码"
    :local ednshost "域名"
    :local ednsinterface "pppoe-out1"
    :local members "http://members.3322.net/dyndns/update?system=dyndns"
    :local status
    :local status [/interface get [/interface find name=$ednsinterface] running]
    :if ($status!=false) do={
    :local ednslastip [:resolve $ednshost]
    :if ([ :typeof $ednslastip ] = nil ) do={ :local ednslastip "0" }
    :local ednsiph [ /ip address get [/ip address find interface=$ednsinterface ] address ]
    :local ednsip [:pick $ednsiph 0 [:find $ednsiph "/"]]
    :local ednsstr "&hostname=$ednshost&myip=$ednsip"
    :if ($ednslastip != $ednsip) do={/tool fetch url=($members . $ednsstr) mode=http user=$ednsuser password=$ednspass
    :delay 2
    :local result [/file get $ednshost contents]
    :log info ($ednshost . " " .$result)
    /file remove $ednshost;
    }
    }

    添加脚本完毕后 新建定时任务

  • 相关阅读:
    TensorRT推理加速基于Tensorflow(keras)的uff格式模型(文件准备)
    pandas_format06
    docker01
    pandas_dataformat03
    pandas_dataformat02
    pandas_series04
    pandas_format05
    pandas_format04
    pandas_dataframe01
    pandas_series03
  • 原文地址:https://www.cnblogs.com/hackkk/p/10106098.html
Copyright © 2011-2022 走看看