Community discussions

MikroTik App
 
howdey57
Member Candidate
Member Candidate
Topic Author
Posts: 122
Joined: Wed Dec 31, 2014 2:36 pm

Static WAN IP not working - mask issue?

Sun Apr 25, 2021 11:09 am

I'm trying to set a static IP address on my WAN (ether1).
I turn off DHCP Client
I add an address x.x.235.129/22 which picks up network x.x.232.0
I add a route to Gateway x.x.232.1
I've made sure my nat is pointing at the correct interface.

Then nothing happens. No internet access, no ping or traceroute outside the home network.

The only thing I can think is that it is a mask issue. I've checked many other things (firewall, DNS etc)

Does anyone have any thoughts on this?

TIA

Charles
 
User avatar
loloski
Member Candidate
Member Candidate
Posts: 296
Joined: Mon Mar 15, 2021 9:10 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:14 pm

I'm trying to set a static IP address on my WAN (ether1).
I turn off DHCP Client
I add an address x.x.235.129/22 which picks up network x.x.232.0
I add a route to Gateway x.x.232.1
I've made sure my nat is pointing at the correct interface.

Then nothing happens. No internet access, no ping or traceroute outside the home network.

The only thing I can think is that it is a mask issue. I've checked many other things (firewall, DNS etc)

Does anyone have any thoughts on thi

TIA

Charles
x.x.235.129/22 are you sure you are part of /22? anyway

ping your_gateway_ip src-address=x.x.235.129 and see if you can ping, if it does then ping 8.8.8.8 src-address=x.x.235.129

Please paste your result here
 
sindy
Forum Guru
Forum Guru
Posts: 10205
Joined: Mon Dec 04, 2017 9:19 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:22 pm

When you say "I turn off DHCP client", does that mean that with DHCP client on, you get some public IP and everything works? But once you assign the same IP address, mask and gateway you have previously obtained using the DHCP client before, it doesn't?
 
howdey57
Member Candidate
Member Candidate
Topic Author
Posts: 122
Joined: Wed Dec 31, 2014 2:36 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:26 pm

@loloski - The ping from my router to my internal IP 192.168.x.1 works. The ping to x.x.235.129 also works. Ping to 8.8.8.8 does not work.
@sindy - hi sindy! Good to see you here. Yes, that's what happens. I copy the IP data into static entries and it doesn't work.

Charles
Last edited by howdey57 on Sun Apr 25, 2021 1:36 pm, edited 1 time in total.
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11433
Joined: Thu Mar 03, 2016 10:23 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:35 pm

It could be that ISP implemented some filtering mechanism and it blocks your router if it doesn't obtain IP address via DHCP. Usually ypu can't just set IP address and assume it'll be static. As your ISP about static IP addresses. Some will set static DHCP lease (in that case take care about MAC adress of WAN interface), some will tell you which IP adress to set (might as well be the one you're currently use but they will unblock it for static use).
 
sindy
Forum Guru
Forum Guru
Posts: 10205
Joined: Mon Dec 04, 2017 9:19 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:37 pm

I copy the IP data into static entries and it doesn't work.
If so, I'd assume the provider uses some kind of protection against people arbitrarily assigning public IPs on their own. In RouterOS, you would do this by setting arp=reply-only in the configuration of the interface and setting add-arp=yes in the configuration of the DHCP server listening at that interface, but there are probably other possible ways.

The DHCP client tries hard to keep renewing the same IP, and the DHCP servers normally have no problem with that. Even if the server has restarted since the previous renewal, it normally assigns the address the client wishes to renew, unless it has already assigned it to some other client in the meantime. So if the provider changes the address, it is most likely an intentional behaviour.
 
howdey57
Member Candidate
Member Candidate
Topic Author
Posts: 122
Joined: Wed Dec 31, 2014 2:36 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:42 pm

@mkx I am beginning to suspect that. Virgin Media in the UK don't give out static IP addresses to residential customers. However, my address has not changed in 2 years so thought I could fixed it to that.

The real reason I tried to fix it is because of this post: viewtopic.php?f=2&t=169115&p=854232#p854232

I get random dhcp-client failures "dhcp-client on ether1 lost IP address xx.xx.xx.xx - lease stopped locally" which is a pain.

I did find something about older CISCO outers not giving out ACKs properly, so causing this issue. I'm not tech enough to know how to track that issue down via my RB4011

Charles
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19101
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:45 pm

Your last post should have been your first post as for most of the thread you were stating you had a fixed WANIP which of course now we know, was NOT a known fact. You must be a politician LOL.
 
howdey57
Member Candidate
Member Candidate
Topic Author
Posts: 122
Joined: Wed Dec 31, 2014 2:36 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 1:48 pm

Oops, sorry. No, not a politician, just an amateur techie! I knew I probably couldn't fix the occasional drop out issue so thought I'd try the fixed IP route. Sorry for any confusion, or rabbit holes.

But help via the other post would be much appreciated!

Charles
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19101
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 4:10 pm

No worries, did you try Sindy's advice. He is usually not wrong (something about selling his soul to the devil in order to be an MT expert). ;-)
 
howdey57
Member Candidate
Member Candidate
Topic Author
Posts: 122
Joined: Wed Dec 31, 2014 2:36 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 4:53 pm

@anav. I didn't try Sindy's advice because it looked like what you would do on the upstream router to me to mimic the behaviour of my ISP.

Sindy has posted on the other thread, so I'm heading over there because I assume I am not able to set a static IP address.

Thanks for your help everyone. As ever, this is a great forum.

Charles
 
sindy
Forum Guru
Forum Guru
Posts: 10205
Joined: Mon Dec 04, 2017 9:19 pm

Re: Static WAN IP not working - mask issue?

Sun Apr 25, 2021 5:08 pm

I didn't try Sindy's advice because it looked like what you would do on the upstream router to me to mimic the behaviour of my ISP.
Sure, you've got it right - that wasn't an advice what to do at your router. There is nothing to advise regarding static address configuration if the ISP only allows traffic from clients who have obtained their address using DHCP.

Who is online

Users browsing this forum: gigabyte091, infabo, massinia, thomassocz and 73 guests