Solved

Force DHCP address assignment

Posted on 2004-08-30
12
3,179 Views
Last Modified: 2011-10-03

    I have a Linksys WRT54G wireless Router.  I have this as my interface to my CableModem, so I can share this connection amongst several computers, some wireless, some not.  I also use the Port Forwarding function, so that specific port requests can be forwarded to a specific computer on the router for processing by specific server software.  The problem is that occasionally, the specific computer on the network will need to be re-booted, and when it does, it does not always get the same IP address.  I would like it to receive 192.168.1.100.  But occasionally it will get the 102 or 101 address.  And then the port forwarding is all messed up.  I have tried setting up the NIC on this computer to use fixed IP instead of DCHP, but since the router is a DCHP router, this doesn't work.  How can I force the router to always give this computer the same IP address?
0
Comment
Question by:beachbt
  • 5
  • 2
  • 2
  • +2
12 Comments
 
LVL 34

Expert Comment

by:PsiCop
ID: 11938685
That functionality is either in the router's DHCP server, or it isn't. If it is, it may or may not be reachable thru whatever config tool has been provided. But forcing a DHCP server to give a specific address to a specific host (usually accomplished with the MAC address) is a capability that may not have been put in there.

I don't understand what you mean by "DHCP router" and the router's desires having anything to do with you being able to force an IP address on the workstation. What happens when you do that?
0
 
LVL 79

Accepted Solution

by:
lrmoore earned 250 total points
ID: 11940731
>I have tried setting up the NIC on this computer to use fixed IP instead of DCHP, but since the router is a DCHP router, this doesn't work.
Sure it will. The router gives out addresses starting with .100
Simply assign your server 192.168.1.99 / 255.255.255.0  gateway 192.168.1.1, nameserver 192.168.1.1
Forward the ports to .99 instead of .100

badabing!
0
 

Author Comment

by:beachbt
ID: 11940948
To PsiCop:  By DHCP Router, I mean the Linksys router.  It assigns IP addresses to the computers that try to connect to it.  But it ASSIGNS addresses, it doesn't process requests for specific addresses.  

To lrmoore:  Thanks, I will give that a shot, and see if the router knows how to handle computers which think they already have an address.  
0
 
LVL 9

Expert Comment

by:Pentrix2
ID: 11941166
if you want a computer to have a specific address at all times through your linksys wireless router, then just assign a static ip address to it.  do ipconfig /all
copy down all the info there, then just paste it in your network properties tcp/ip configurations.  easiest way to me if i would do this.
0
 

Author Comment

by:beachbt
ID: 11941191
To Pentrix2:

     As I mentioned in the original problem statement, I have tried this, and it fails.  The router does not assign this (or ANY) address to the computer when I configure a fixed IP address for the NIC.
0
 
LVL 9

Expert Comment

by:Pentrix2
ID: 11941212
when you assign the ip, of course the router doesn't assign it. but as long as you got the default gateway in there, it should work.  what OS are you using, xp professional or 2000?  and what error message is it giving you when you assign a fixed ip, is it letting you and your port forwarding not working?  are you able to pull up the router's configuration up with the fixed ip in place?
0
Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

 
LVL 34

Expert Comment

by:PsiCop
ID: 11942105
Hmmm...I wonder if the router will refuse to route IP traffic from an address to which it has not leased an IP address? I mean, its specifically designed to do that. I don't see the point of such a limitation, tho.
0
 

Author Comment

by:beachbt
ID: 11942479
I think lrmoore may be onto something, selecting an address outside the lease range, but won't know if linksys will allow routing outside that range until I try it.  Which I will do when I get home tonight.
0
 
LVL 11

Expert Comment

by:PennGwyn
ID: 11943876
There are two ways to do this:

1.  Assign a static address within the subnet, but outside the DHCP scope.  lrmoore has suggested this already, and he is correct.

2.  Assign a "reservation" in the DHCP service, so that this machine's MAC address will always be assigned the specified address.  This is a better choice, for several reasons:

a.  You can leave the client configured to get configuration from DHCP.  Odds are that this will continue to work if/when you move the machine to another network.

b.  All of the parameters that DHCP sets -- mask, gateway, DNS, etc -- remain controlled from a single place, so if you need to change any of them, you only need to do it there.

Now if you don't do either 1 or 2, you run the risk that you will statically assign an address in the DHCP scope.  The DHCP server won't know you've done that, so it will feel free to offer that address to another client.  And at least one of the machines that now have this address will stop working.

Although they're routinely implemented in the same box, "router" and "DHCP server" are functionally orthogonal.  The router function has no business tracking the DHCP lease database, and will be considered "broken" if it does so.  The only useful connection I can see between them would be if the lease database were used to populate the ARP cache to reduce broadcast traffic, and although that should work, it might not be legal.  And while it would slightly optimize service for DHCP clients, it wouldn't break service for non-clients.



0
 

Author Comment

by:beachbt
ID: 11945414
To PennGwyn:  
   I wish there were a way to "reserve" IP addresses in the Linksys DHCP setup, much like the port forwarding works.  But as far as I can tell, there is not way to do this with this Linksys.
0
 
LVL 79

Expert Comment

by:lrmoore
ID: 11945645
beachbt,
that is true. While the dhcp features make this a nice little SOHO router that just works right out of the box, there are no advanced features like that to turn it into an enterprise-ready DHCP server.

I've been using Linksys for several years and I know for a fact that all you have to do is use a static IP address that is outside the scope of the DHCP server which starts at 100 and continues up to the maximum number that you have specified. Anything between .2 and .99 is fair game to use as static IP's..

0
 

Author Comment

by:beachbt
ID: 11947630
Setting Fixed IP to .99 and setting Gateway and DNS to 192.168.1.1 worked like a charm.  Many thanks.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Hello , This is a short article on how would you go about enabling traceoptions on a Juniper router . Traceoptions are similar to Cisco debug commands but these traceoptions are implemented in Juniper networks router . The following demonstr…
There are two basic ways to configure a static route for Cisco IOS devices. I've written this article to highlight a case study comparing the configuration of a static route using the next-hop IP and the configuration of a static route using an outg…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now