Follow us on...
Follow us on G+ Follow us on Twitter Follow us on Facebook Watch us on YouTube
Register
Page 2 of 2 FirstFirst 12
Results 16 to 19 of 19
  1. #16
    Status
    Offline
    bontot68's Avatar
    Newbie
    Join Date
    Aug 2010
    Posts
    56
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    Gw udh coba script dibawah ini :

    #netwatch
    / tool netwatch
    add host="ip Yahoo" timeout=1000ms interval=20s up-script=Up down-script=Down comment="" disabled=no

    #Koneksi Up
    /system script
    add name=Up policy=ftp,reboot,read,write,policy,test,winbox,pa ssword source={:if ([/ping "Ip Yahoo interval=1 count=20] =1) do={log info "Up" ; /tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Up" body="Speedy Up"}}

    #Koneksi Down
    /system script
    add name=Down policy=ftp,reboot,read,write,policy,test,winbox,pa ssword source={:if ([/ping "ip Yahoo" interval=1 count=20] =0) do={log info "Down" ; /tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Down" body="Speedy Down"}}

    Hasilnya klo koneksi down saja email diterima setelah 30 detik rto, tapi klo udh up koneksinya (alias sudah tidak rto), tidak dapat kiriman email

    Tolong dibantu ya....
    Last edited by bontot68; 22-02-2012 at 18:44.

  2. #17
    Status
    Offline
    d0n juant's Avatar
    Baru Gabung
    Join Date
    Apr 2009
    Posts
    15
    Reviews
    Read 0 Reviews
    Downloads
    1
    Uploads
    0
    Feedback Score
    0
    Click here to enlarge Originally Posted by bontot68 Click here to enlarge
    Gw udh coba script dibawah ini :

    #netwatch
    / tool netwatch
    add host="ip Yahoo" timeout=1000ms interval=20s up-script=Up down-script=Down comment="" disabled=no

    #Koneksi Up
    /system script
    add name=Up policy=ftp,reboot,read,write,policy,test,winbox,pa ssword source={:if ([/ping "Ip Yahoo interval=1 count=20] =1) do={log info "Up" ; /tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Up" body="Speedy Up"}}

    #Koneksi Down
    /system script
    add name=Down policy=ftp,reboot,read,write,policy,test,winbox,pa ssword source={:if ([/ping "ip Yahoo" interval=1 count=20] =0) do={log info "Down" ; /tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Down" body="Speedy Down"}}

    Hasilnya klo koneksi down saja email diterima setelah 30 detik rto, tapi klo udh up koneksinya (alias sudah tidak rto), tidak dapat kiriman email

    Tolong dibantu ya....

    Kalo udah pake netwach, apa gk lebih bagus scriptnya disederhanakan aja gan..Gk usah pake ping lg di script

    jadi kalo udah pake :
    Code:
    / tool netwatch
    add host="ip Yahoo" timeout=1000ms interval=20s up-script=Up down-script=Down comment="" disabled=no
    sebaiknya di /system script jadi gini :
    Code:
    /system script
    add name=Up policy=ftp,reboot,read,write,policy,test,winbox,password source=/tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Up" body="Speedy Up"
    add name=Down policy=ftp,reboot,read,write,policy,test,winbox,password source=/tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Down" body="Speedy Down"
    CMIIW

  3. #18
    Status
    Offline
    bontot68's Avatar
    Newbie
    Join Date
    Aug 2010
    Posts
    56
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    [QUOTE=d0n juant;242429]Kalo udah pake netwach, apa gk lebih bagus scriptnya disederhanakan aja gan..Gk usah pake ping lg di script[/CODE]

    sebaiknya di /system script jadi gini :
    Code:
    /system script
    add name=Up policy=ftp,reboot,read,write,policy,test,winbox,password source=/tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Up" body="Speedy Up"
    add name=Down policy=ftp,reboot,read,write,policy,test,winbox,password source=/tool e-mail send to="xxxx@gmail.com" tls=yes subject="Speedy Down" body="Speedy Down"
    Klo pake script diatas, otomatis RTO 1 kali saja, langsung menjalankan script, tp klo menggunakan script :if [/ping "Ip Yahoo interval=1 count=20] =1 setelah 30 detik RTO baru script dijalankan.
    Masalahnya kenapa pas kondisi up, script tidak jalan, pada kondisi down, script otomatis 30 detik kemudian jalan.

  4. #19
    Status
    Offline
    4n4kw38's Avatar
    Newbie
    Join Date
    Dec 2011
    Posts
    65
    Reviews
    Read 0 Reviews
    Downloads
    0
    Uploads
    0
    Feedback Score
    0
    Kalo kayak yang ane buat dibawah ini bisa ga? ane menggunakan pcc loadbalancing bila jalur international down.

    CARA PERTAMA buat /system script di bawah ini:
    Name = ISP1-DOWN
    :local i 0; {:do {:set i ($i + 1)} while (($i < 15) && ([/tool traceroute ip-address-ix interface=ehter1-ISP1 routing-table=to_ISP1 interval=1 count=20]=0))};
    :if ($i=15 && [/ip route get [find comment="Gateway ISP1 Distance"] distance]=1) do={:log info "Jalur IX ISP1 slowly/down";
    /tool e-mail send to="xxxxx@domain.com" tls=yes subject="Jalur IX ISP1 slowly/down" body="Jalur IX ISP1 slowly/down dan sudah di alihkan ke ISP2";
    /ip route set [find comment="Gateway ISP1 Distance"] distance=2}
    Name = ISP2-UP
    :local i 0; {:do {:set i ($i + 1)} while (($i < 15) && ([/tool traceroute ip-address-ix interface=ehter5-ISP2 routing-table=to_ISP2 interval=1 count=20]=0))};
    :if ($i=5 && [/ip route get [find comment="Gateway ISP2 Distance"] distance]=2) do={:log info "Jalur IX ISP2 normal";
    /tool e-mail send to="xxxxx@domain.com" tls=yes subject="Jalur IX ISP2 normal" body="Jalur IX ISP2 normal dan sudah teralihkan";
    /ip route set [find comment="Gateway ISP2 Distance"] distance=1}
    / tool netwatch
    add host="ip-address-ix" timeout=500ms interval=10s up-script=ISP2-UP down-script=ISP1-DOWN comment="" disabled=no

 

 
Page 2 of 2 FirstFirst 12

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. tolong dibantu
    By ewind in forum Beginner Basics
    Replies: 4
    Last Post: 23-03-2008, 01:02
  2. Tolong di Bantu ya........
    By Rifq in forum Wireless Networking
    Replies: 24
    Last Post: 28-02-2008, 23:22
  3. Minta tolong?
    By adhit in forum Wireless Networking
    Replies: 1
    Last Post: 13-11-2007, 14:49
  4. Help...Script untuk memantau Netwatch
    By dedykristiawan in forum Scripting @ Mikrotik
    Replies: 1
    Last Post: 26-10-2007, 19:19
  5. Tolong....
    By reiden in forum Beginner Basics
    Replies: 2
    Last Post: 26-09-2007, 20:15

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •