PDA

View Full Version : DHCP mapping to Hostname



n2ize
07-26-2011, 10:32 AM
How do I go about creating a mapping to a hostname for machines connected to my network. For instance, a device logs onto my network and the system leases them an ip addy, say "192.168.2.199". How do I map that to a hostname, say, "foo.mynetwork". The lease expires and next time the DGCP leases the addy "192.168.2.195" and I want this new addy to map to the same hostname. This way given device can be accesses via hostname regardless of the leased address. i tried manipulating the config files but no luck. Any ideas ?

KC2UGV
07-26-2011, 10:52 AM
How do I go about creating a mapping to a hostname for machines connected to my network. For instance, a device logs onto my network and the system leases them an ip addy, say "192.168.2.199". How do I map that to a hostname, say, "foo.mynetwork". The lease expires and next time the DGCP leases the addy "192.168.2.195" and I want this new addy to map to the same hostname. This way given device can be accesses via hostname regardless of the leased address. i tried manipulating the config files but no luck. Any ideas ?

You can specify a hostname to be given to the machine upon lease granting when giving static assignments. Otherwise, the router should have some sort of rudimentary DNS server running, then you can specify your router as your DNS server.

n2ize
07-27-2011, 03:03 PM
Okay, I think that's basically what I am doing now. I am using a Linux box as a router, DNS server, web server, mail server, ftp server, Gopher server, you name it... Stationary workstations are simply set up to use a static address which never changes and is always attached to a specific hostname. They are also hard wired to the network, as in Cat 5 cable. Mobile devices, lap tops, iPods, cell phones, or other devices that drift on and off the network are automatically leased an address via DHCP protocol. However, they are not mapped to a hostname., they are addressed only by their assigned ip number. Only the stationary, hard wired work stations are set to a fixed static ip addy and mapped to a specific unchanging hostname.

KC2UGV
07-28-2011, 06:42 AM
Okay, I think that's basically what I am doing now. I am using a Linux box as a router, DNS server, web server, mail server, ftp server, Gopher server, you name it... Stationary workstations are simply set up to use a static address which never changes and is always attached to a specific hostname. They are also hard wired to the network, as in Cat 5 cable. Mobile devices, lap tops, iPods, cell phones, or other devices that drift on and off the network are automatically leased an address via DHCP protocol. However, they are not mapped to a hostname., they are addressed only by their assigned ip number. Only the stationary, hard wired work stations are set to a fixed static ip addy and mapped to a specific unchanging hostname.

Hm... All the devices should register with the DNS server upon lease acquisition. Did you enable client registration?

http://download.oracle.com/docs/cd/E19963-01/html/821-1453/dhcp-admin-51.html#dhcp-admin-303

(http://download.oracle.com/docs/cd/E19963-01/html/821-1453/dhcp-admin-51.html#dhcp-admin-303)As an aside, I'd split some of your boxes up. Especially if the gopher/mail/ftp/etc are publicly available. Not wise to put your router on the same box as your public services.

n2ize
07-28-2011, 05:55 PM
Hm... All the devices should register with the DNS server upon lease acquisition. Did you enable client registration?

http://download.oracle.com/docs/cd/E19963-01/html/821-1453/dhcp-admin-51.html#dhcp-admin-303

I didn't enable client registration. Up until a while ago I was onyl using fixed workstations with static addresses on this network. When I added on a wireless access I set up DHCP so that family members, certain friends, my neices, could get Internet access on their laptops and mobile/portable wireless devices. In a pinch I set it up quick and never bothered with the finer config details. I checked out the link you posted. I'll give it a go.



(http://download.oracle.com/docs/cd/E19963-01/html/821-1453/dhcp-admin-51.html#dhcp-admin-303)As an aside, I'd split some of your boxes up. Especially if the gopher/mail/ftp/etc are publicly available. Not wise to put your router on the same box as your public services.

Except for a select service or two that floats on and off the Internet most of the services on that box are local only and are not open to the public. However, I have some overdue work to do on that network. The server is an old machine and I want to upgrade both the hardware and the software. I also want to install a new drive as the one that its running on now is quite old and has been chugging along for years and is probably getting close to its max life span. I will say though, for an old machine, chugging along on an old version of fedora it runs 24/7/365 and has been very dependable. Only time it went down was this past winter when we were having a new boiler installed and one of the plumbers must have bumped a switch and took it down. In any event I better get busy on it so I can avoid that scenario where one day I notice the network is down and I end up frantically configuring a whole new machine.