# apr/14/2011 15:30:21 by RouterOS 4.17
# software id = Y2DT-TVQB
#
/system scheduler
add comment="" disabled=no interval=1d name=paketdinihari-enable on-event=":fo\
reach i in=[/tool user-manager user find credit-price=1000000 uptime-limit\
=10h] do={\r\
\n:log info \"Paket dinihari nyala\";\r\
\n/tool user-manager user enable numbers=\$i;\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=22:00:00
add comment="" disabled=no interval=1d name=paketdinihari-disable on-event=":f\
oreach i in=[/tool user-manager user find credit-price=1000000 uptime-limi\
t=10h] do={\r\
\n:log info \"Paket dinihari mati\";\r\
\n/tool user-manager user disable numbers=\$i;\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=06:00:00
add comment="" disabled=no interval=0s name=pln-mati on-event=":delay 00:01:00\
;\r\
\n:local hour;\r\
\n:local hournow;\r\
\n:set hour [:totime [/system clock get time]];\r\
\n:set hournow [:tonum [:pick \$hour 0 2]];\r\
\n#:log info \$hournow;\r\
\n:if (([\$hournow] >= 22)||([\$hournow] <= 6)) do={\r\
\n:log info \"Paket dinihari nyala\";\r\
\n\t:foreach i in=[/tool user-manager user find credit-price=1000000 uptim\
e-limit=10h] do={\r\
\n\t/tool user-manager user enable numbers=\$i;\r\
\n\t}\r\
\n} else={\r\
\n:log info \"Paket dinihari mati\";\r\
\n\t:foreach i in=[/tool user-manager user find credit-price=1000000 uptim\
e-limit=10h] do={\r\
\n\t/tool user-manager user disable numbers=\$i;\r\
\n\t}\r\
\n\t\r\
\n}\r\
\n\r\
\n:if (([\$hournow] >= 18)||([\$hournow] <= 6)) do={\r\
\n:log info \"Paket malam nyala\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"din1\") || (\$kodepaket = \"din2\") || (\$kodepake\
t = \"san1\") || (\$kodepaket = \"san2\") || (\$kodepaket = \"san3\")) do=\
{\r\
\n/tool user-manager user enable \$i;\r\
\n}\r\
\n}\r\
\n} else={\r\
\n:log info \"Paket malam mati\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"din1\") || (\$kodepaket = \"din2\") || (\$kodepake\
t = \"san1\") || (\$kodepaket = \"san2\") || (\$kodepaket = \"san3\")) do=\
{\r\
\n/tool user-manager user disable \$i;\r\
\n}\r\
\n}\r\
\n}\r\
\n:if (([\$hournow] >= 9)&&([\$hournow] <= 14)) do={\r\
\n:log info \"Paket pagi nyala\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"pagi\") || (\$kodepaket = \"sara\")) do={\r\
\n/tool user-manager user enable \$i;\r\
\n}\r\
\n}\r\
\n} else={\r\
\n:log info \"Paket pagi mati\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"pagi\") || (\$kodepaket = \"sara\")) do={\r\
\n/tool user-manager user disable \$i;\r\
\n}\r\
\n}\r\
\n}\r\
\n" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-time=startup
add comment="" disabled=no interval=1d name=paketmalam-enable on-event=":log i\
nfo \"Paket malam nyala\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"din1\") || (\$kodepaket = \"din2\") || (\$kodepake\
t = \"san1\") || (\$kodepaket = \"san2\") || (\$kodepaket = \"san3\")) do=\
{\r\
\n/tool user-manager user enable \$i;\r\
\n}\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=18:00:00
add comment="" disabled=no interval=1d name=paketmalam-disable on-event=":log \
info \"Paket malam mati\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"din1\") || (\$kodepaket = \"din2\") || (\$kodepake\
t = \"san1\") || (\$kodepaket = \"san2\") || (\$kodepaket = \"san3\")) do=\
{\r\
\n/tool user-manager user disable \$i;\r\
\n}\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=05:00:00
add comment="" disabled=no interval=1d name=paketpagi-enable on-event=":log in\
fo \"Paket pagi nyala\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"pagi\") || (\$kodepaket = \"sara\")) do={\r\
\n/tool user-manager user enable \$i;\r\
\n}\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=09:00:00
add comment="" disabled=no interval=1d name=paketpagi-disable on-event=":log i\
nfo \"Paket pagi mati\";\r\
\n:local kodepaket;\r\
\n:foreach i in=[/tool user-manager user find] do={\r\
\n:set kodepaket [:pick [/tool user-manager user get \$i name] 0 4];\r\
\n:if ((\$kodepaket = \"pagi\") || (\$kodepaket = \"sara\")) do={\r\
\n/tool user-manager user disable \$i;\r\
\n}\r\
\n}" policy=reboot,read,write,policy,test,password,sniff,sensitive \
start-date=jan/01/1970 start-time=14:00:00
4 years ago
No comments:
Post a Comment