Community discussions

MikroTik App
 
plisken
Forum Guru
Forum Guru
Topic Author
Posts: 2509
Joined: Sun May 15, 2011 12:24 am
Location: Belgium
Contact:

delay a script by 4 seconds.

Fri Nov 01, 2019 1:30 am

I want to delay a script by 4 seconds.
/ ip firewall connection remove [find]

How should I set this?

Thanks for your help.
 
User avatar
inteq
Member
Member
Posts: 412
Joined: Wed Feb 25, 2015 8:15 pm
Location: Romania

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 3:28 am

:delay 4000ms;
But I feel there is more to your question than a simple delay
 
plisken
Forum Guru
Forum Guru
Topic Author
Posts: 2509
Joined: Sun May 15, 2011 12:24 am
Location: Belgium
Contact:

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 9:04 am

Thanks for your reply

The problem is that I don't know where to place the delay in the script.

Something like that or am I wrong
/ ip firewall connection remove [find] :delay 4000ms;
 
User avatar
inteq
Member
Member
Posts: 412
Joined: Wed Feb 25, 2015 8:15 pm
Location: Romania

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 5:10 pm

You want a delay after each entry from firewall is removed? Or after all entries are removed?
 
plisken
Forum Guru
Forum Guru
Topic Author
Posts: 2509
Joined: Sun May 15, 2011 12:24 am
Location: Belgium
Contact:

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 5:44 pm

I want to run a script and pause the last line for 4 seconds

ip route disable [find dst-address=0.0.0.0/0 gateway=xx.xx.xx.xx]
:log error "ISP2 is down"
Here must come the pause for this below command

/ip firewall connection remove [find]

Thanks for your effort.
 
Dude2048
Member Candidate
Member Candidate
Posts: 212
Joined: Thu Sep 01, 2016 4:04 pm

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 6:58 pm

Ip route disable [find dst-address=0.0.0.0/0 gateway=xx.xx.xx.xx]
:log error "ISP2 is down"
:delay 4000 ms
/ip firewall connection remove [find
 
plisken
Forum Guru
Forum Guru
Topic Author
Posts: 2509
Joined: Sun May 15, 2011 12:24 am
Location: Belgium
Contact:

Re: delay a script by 4 seconds.

Fri Nov 01, 2019 8:56 pm

Thanks for your help. I appreciate this.

Greatings

Who is online

Users browsing this forum: abbio90 and 67 guests