Highlighted
Ubiquiti Employee
Posts: 4,155
Registered: ‎12-10-2015
Kudos: 1471
Solutions: 315

New plugin has been released - suspension rules sync to Mikrotik routers.

Hi all,

we have released a new plugin for Suspension Feature on Mikrotik routers.

 

Note that this plugin is compatible only with UNMS v1 and its CRM module and it's not compatible with current UCRM v2 as this plugin is replacing the current Suspension Feature support for Mikrotik devices which will be removed during the migration from UCRM v2 to UNMS.

 

2019-05-14_16-09.png

 

If you are using UCRM v2 you don't need this plugin, you can continue using the current mikrotik suspension feature.

 

To all developers: feel free to extend or improve this plugin and share your code with others. You might find a better way how to handle the sync of the suspension rules or sync of the blocked IPs.

Regular Member
Posts: 405
Registered: ‎01-18-2017
Kudos: 132
Solutions: 13

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

[ Edited ]

Thank you for releasing this. Without this support we would never have migrated from UCRM to UNMS/UCRM combo. Is this plugin basically the same code used today in UCRM?

 

Member
Posts: 216
Registered: ‎04-26-2013
Kudos: 88
Solutions: 3

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

weeeee

/Simon
New Member
Posts: 15
Registered: ‎09-07-2017
Kudos: 1
Solutions: 1

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

Perfect! Now we only need the mailing feature by sites and we can migrate

New Member
Posts: 21
Registered: ‎01-03-2019
Kudos: 35

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

[ Edited ]

It's strange but i can not get adding ips to blocked list working... I have a api user in my CCR with api/read/write permissions. It was working with UCRM system. I remove firewall rules and plugin creates again, but not ips in block adress list...

 

I suspect that the problem is in the UNMS api token so plugin can not get IP... User api log in UNMS -> Last used: never

New Member
Posts: 15
Registered: ‎09-07-2017
Kudos: 1
Solutions: 1

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

Try suspening a client .

Pretty sure it only sync the ips to the router when a suspention or activation happens 

 

New Member
Posts: 21
Registered: ‎01-03-2019
Kudos: 35

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

[ Edited ]

It was the first thing i thought... but not working. 

 

In fact devices appears as suspended in UNMS devices list, but no IPs in RouterOS blocked list and it is possible to navigate throught this "suspended" devices...

Ubiquiti Employee
Posts: 4,155
Registered: ‎12-10-2015
Kudos: 1471
Solutions: 315

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

@clarkraymond > Is this plugin basically the same code used today in UCRM?
yes, it's basically the same code, which is now open and anyone can improve or extend it.

@dantronik > Now we only need the mailing feature
The next alpha version comprises this filter. Follow the alpha forum for the release notes.

@asysto @dantronik
The sync is not triggered at the moment of suspending the client. Currently, the plugin syncs the blocked IP list every 5mins - the plugin execution interval which can be configured in the plugin settings. This might be improved in the future plugin development - by the webhooks which could trigger the plugin's sync. Check out the info:
https://github.com/Ubiquiti-App/UCRM-plugins/tree/master/plugins/routeros-suspension
New Member
Posts: 21
Registered: ‎01-03-2019
Kudos: 35

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

[ Edited ]

@UBNT-Petr: I know, And I know it's possible to modify the trigger time. I waited for more than 5 minutes, and i performed a manual execution of the plugin too... When i do the plugin work it creates rules in firewall in the right way if i have removed them before... but nothing with the IPs.

New Member
Posts: 21
Registered: ‎01-03-2019
Kudos: 35

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

Has anyone managed to reproduce this bug?

New Member
Posts: 9
Registered: ‎11-01-2018
Kudos: 1

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

I Have Exactly the same issue. Everything else syncs with the router (Firewall/Nat) Except Blocked IP's Ive tried everything. Same problem here with UNMS stating the API Key has never been used. Seems like UCRM isnt calling the UNMS API.

New Member
Posts: 9
Registered: ‎11-01-2018
Kudos: 1

Re: New plugin has been released - suspension rules sync to Mikrotik routers.

I Have Exactly the same issue. Everything else syncs with the router (Firewall/Nat) Except Blocked IP's Ive tried everything. Same problem here with UNMS stating the API Key has never been used. Seems like UCRM isnt calling the UNMS API.