Community discussions

MikroTik App
 
jober
Long time Member
Long time Member
Topic Author
Posts: 690
Joined: Fri May 28, 2004 12:16 pm
Location: Louisiana,USA

Need Help w/Mass Flashfig script

Thu Feb 16, 2017 9:03 am

Complexed script and I need help!
I need to configure 250 hAP lite routers and 250 wAP APs so I plan to use flashfig for the job.
The hAP and wAP are paired for each condo unit. The config for each unit needs to have a few things different, like Identity, SSID, WPA password, LAN Address and the WAN Address. The wAP will only run as an access point, so I hope to get its config from the hAP running CAPsman. I think this is a good way to handle the APs just in case I need two APs per unit or replace a wAP.
I don’t know of any way to do this other than what is below. If there is a better way, please let me know.
There would need to be a netwatch set to check for the WAN Address before many of the below could start. Once the Address is received from the DHCP server the hAP would have a public IP Address of “abc.def.180.250”. I then need a script to create an SSID by using the 4th octet of that WAN IP Address. The SSID would be set to “wifi-250”.
The script would again use the public IP Address for the WPA2 password in this reverse format, “250180defabc” or if that’s too hard just the IP address without the dots “.” like this “abcdef180250”.
The script needs to set the LAN network address by using the last octet in the WAN IP Address as its 3rd octet of its private Address “192.168.250.0/24”.
The script needs to set a NAT rule to src nat to the WAN IP Address.
Set the Identity to the same IP scheme as the SSID “250”.

The ideal thing would be to have the Identity and SSID set to the unit/apartment number but that would make the whole process much harder for me to handle. The way I’m wanting to do it is what I hope to be an easy one script to flashfig and done. Although I think the CAPsman is going to bite me on the ass because it will not be plugNplay.
 
Dude2048
Member Candidate
Member Candidate
Posts: 212
Joined: Thu Sep 01, 2016 4:04 pm

Re: Need Help w/Mass Flashfig script

Mon Feb 20, 2017 4:30 pm

http://forum.mikrotik.com/viewtopic.php ... 67#p574904

Similar problem and how I solved it.
 
User avatar
BrianHiggins
Forum Veteran
Forum Veteran
Posts: 702
Joined: Mon Jan 16, 2006 6:07 am
Location: Norwalk, CT
Contact:

Re: Need Help w/Mass Flashfig script

Mon Feb 20, 2017 11:59 pm

This is actually exactly what our company does...

We have a complete process for this, including automated provisioning and tenant account management, bandwidth controls, IP provisioning, etc.

brian at aditumims dot com for details.

Who is online

Users browsing this forum: ko00000000001, normis and 19 guests