Hi all, MrNewbie here again, and i came with another easy to solve problem for you but hard as rocket since for me.
This is it,
Port 1 is going to my ISP who broadcast DHCP to my port, all ports are connected to bridge 1, other ports are for my customers networks and they use the DHCP server of my ISP to get their IPs.
How can i do independent DHCP server for each port and keep them connected to my ISP (port 1) at the same time so i won’t run out of IPs eventually?
I’m confused. You say that all ports are “connected to bridge1” and “other ports are for customers”. How can you have “other ports for customers” and “all ports on bridge1”?
You can’t have it all. If you use the ISP’s DHCP, you can’t put your own DHCP for the customers while they’re using the ISP’s. For bridge1, that’s easy. Just assign that bridge an IP address and then create it’s DHCP Server. You’ll need a NAT (masquerade) rule for bridge1 (in-interface) going out the “X” interface (out-interface).
For the rest, please be more precise as to what you want to do. Again, your description is somewhat confusing, or maybe it’s “Friday’s” fault
So basically what i have here is a dumb switch and i have nothing to route.
What i want is to add DHCP server for each one of these ports and to use port 1 as WAN to these ports.
Remove ether1 from bridge1 and give it (ether1) a dhcp-client. It’ll get an address from the ISP. Don’t forget to have the dhcp-client add a default route, otherwise no Internet routing.
Then, as per my last post, give bridge1 an IP address and a DHCP server (use the setup button for that!! Don’t do it manually).
Add a NAT (schain=srcnat, action=masquerade) rule with ether1 as “out-interface”.
From there, you’re good to go!
Of course, at this point you have NO security. So you must implement a firewall. After, you can configure your router with the desired functions and security features (such as disabling not needed IP services and packages). So yes, you still have to do your due diligence for the rest.
Why are you trying to get IP addresses on ether11? You have no IP addresses on it, and no DHCP server. It’ll never work. Why didn’t you show us the IP addresses in the first code capture. That would have been useful. I can only assume you didn’t have one or are using the 192.168.10.1/24, in which case you had a totaly misconfigured router.
I couldn’t understand why are you saying this and where did i improvised!! is it the way how i talk or compose words that made you think so? (Totally confused)
Anyway, I’m not trying to hide something here and i wrote the IPs when i needed them otherwise i only had a basic switch setup and that was the first code i showed you.
Now, why i need IPs on ether11 is might be not exactly what i want because i don’t have an idea so far on how or what must be done to get what i want. I need to use ether11 for management and to access my customers from it because most of them are connected by wireless CPEs and i need to access their devices periodically to add or change frequencies and to monitor my APs as well because now they are located after the DHCP servers of each port. (Notice that i only made a test for now on ether10 only to see how this setup will work)
For now, from the costumers side i can get an IP and the ad page of my ISP is pop up as usual but broadband connections are not working.
I can ping to my ISP DNS servers with no problems but no internet connection is possible due the lack of establishing broadband connection.
It has nothing to do with your writing style, that’s good. But I don’t understand why you change values that you shouldn’t touch like relay in dhcp-server and distance in static routes. Also, on ether10 you change from 10.10.10.0/24 to 192.168.10.0/24. That is totaly confusing (and frustrating) to me because you’re asking for help and changing stuff as you go along.
Now, why i need IPs on ether11 is might be not exactly what i want because i don’t have an idea so far on how or what must be done to get what i want.
But I wrote it all down yesterday!
OK, let’s recap.
If required, backup current config and flush it to make sure you have no leftover ghosts in there.
You have ether12 on ISP
You have ether10 on one subnet
You want ether11 on another subnet
Here’s a summary of what needs to be done.
ether10, 11 and 12 should not be in any bridge
Have NAT rule with ether12 as out-interface and action=masquerade, chain=srcnat
ether12
(If your ISP has it’s own DHCP-SERVER)
add dhcp-client with default parameters for now
As you click OK, validate that you get an IP address on it. Validate that in /ip routes, you have your default route with the gateway’s value being the IPS’s router’s address. Distance should be “1”
(If your ISP doesn’t have it’s own DHCP-SERVER)
add an ip address to ether12 from the pool provided by the ISP
add the default route with the gateway’s value being the IPS’s router’s address. Distance should be “1”
At this point, ping 8.8.8.8. It must work. If not, go no further, it will be pointless. Check the NAT rule, the routing table, your IP address on ether12.
ether10
add IP
add DHCP-Server using “DHCP Setup” button. Use default parameters for now
ether11
add IP
add DHCP-Server using “DHCP Setup” button. Use default parameters for now
At this point, plug your PC in ether11. You should get an IP address. Surf the Internet to validate connectivity and proper routing.
At this point, you have no firewalls. So go to my earlier posts on that and read it over again.
Now i see your meaning of improvised. Please check #9 post, i mentioned that it worked this way, i watched a video on YouTube and repeated the steps and it worked but the only one problem was that i could’t establish PPPOE conecction. As to why i used the Youtube method is because your way did not work.
As to the relay and why i added it is because it was there by default when i was setting the DHCP server, i might be confused about this but this is what i can remember from yesterday, i even don’t know what does it do to the DHCP server.
As to pinging to 8.8.8.8 is not possible without establishing a broadband connection (PPPOE), but when i used the setup in post #9 i could ping the DNS servers of my ISP, but now after doing exactly what you have told me to do i could no longer ping to the DNS servers (109.224.14.2, 109.224.14.3).
This is a full code of my current setup as to what you told me to do:
I’m happy I am not your “customer”!
And I advise you to hire a networking consultant…
Establishing an ISP requires a bit more than buying a shiny box and doing some forum posts.
I’m trying my best to learn as possible as i could in matter of routing and switching (I’m well good with wireless).
I learned today not to ask professionals because they would not be patience with starters guys like me and possibly they would make fun of me and that wasn’t nice for sure.
Also i would like to say that i picked the name MrNewbie for a reason, and that is i wanted to learn from you.