Create a schedule and then issue command to disable or enable queue on event
Or set different packet marking rules in mangle table based on time schedule:
/ip firewall mangle
add chain=prerouting action=mark-connection time=0h-6h,sun,mon,tue,wed,thu,fri,sat new-connection-mark=night
add chain=prerouting action=mark-connection time=6h-1d,sun,mon,tue,wed,thu,fri,sat new-connection-mark=day
The beauty here is that the rule becomes inactive (ok, "invalid") outside its specified time, so it is not processed at all so doesn't waste resources:
[me@MyTik] > /ip firewall mangle print where action=mark-connection
Flags: X - disabled, I - invalid, D - dynamic
0 I ;;; inactive time
chain=prerouting action=mark-connection new-connection-mark=night time=0s-6h,sun,mon,tue,wed,thu,fri,sat
1 chain=prerouting action=mark-connection new-connection-mark=day time=6h-1d,sun,mon,tue,wed,thu,fri,sat
The
of the rule can be a
to a chain of classification rules of course.