0

When I set a static IP on my device, it works for a short time, then it won't connect again unless I do DHCP. It's like the router chooses an IP for the device, and only allows it to use that one. Why is this happening?

The same thing happened a while ago with my desktop, I wanted to set a static IP so I could access it from another building, and the router, being the piece of crap it is, reset all the IPs, and wouldn't allow the computer to connect.

D-Link WBR-1310, Hardware B1, Firmware 2.02

7
  • Are you using a static IP that is inside your DHCP address range? Feb 10, 2013 at 19:48
  • @mossy What to you mean? It's 192.168.0.xxx
    – tkbx
    Feb 10, 2013 at 19:48
  • It's 2 to 154, and the IP I'm trying is in that range
    – tkbx
    Feb 10, 2013 at 19:55
  • Trying using 192.168.0.155 as a static Feb 10, 2013 at 19:57
  • A router can't reset a computer's static IP. A computer controls what its IP address is; DHCP lets it ask the router for an unused IP, but the router can't force the computer to change a static IP.
    – cpast
    Feb 10, 2013 at 20:09

1 Answer 1

4

Local subnet traffic doesn't need to go through the router, in a simple network where the entire local subnet is on the same later 2 link; broadcast ARP will resolve MACs and from there you just send your packet to its destination. Obviously no routing is needed.

However, there are two complications I can see if you are using a home router+WAP in this case.

First, if you assign a static IP that is within the DHCP pool and do not create a DHCP reservation (your router+stuff may or may not support this), the thing may assign that address via DHCP to some other host. This would create an IP conflict, causing connectivity issues pretty much at random.

Second, if you have a mixed later 2 (eg. wired 802.3 and wireless 802.11), it is possible that your router+WAP's WAP functions are filtering MAC/IP pairs that it did not assign via DHCP (instead of bridging them across the layer 2 gap). In this case, you will have to create a DHCP reservation and probably not assign the address as static on the host (instead allowing DHCP to just give the same address each time).

If your firmware doesn't support this, consider flashing with openwrt, tomato, or dd-wrt.

It is worth noting that the router on a network doesn't control what addresses a host uses. DHCP is a mechanism for doing so in a way, but it isn't mandatory and won't override static configuration.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .