DHCP Client Hostname Issue

DHCP Client Hostname Issue

Post by Logan Sh » Fri, 07 Sep 2001 09:23:37





Quote:>Is there any way to define a hostname for a DHCP client machine... The
>DHCP server here doesn't push one out so Ialways have unknown, which
>givees me goofy problems.

Yeah, that is irritating.  You can do this:

        # patch -b /etc/init.d/network << END_OF_PATCH
        *** network     Wed Apr 18 07:50:24 2001
        --- network     Wed Sep  5 19:19:49 2001
        ***************
        *** 834,840 ****
          # name, default to "unknown"
          #
          if [ -z "$hostname" ]; then
        !       hostname="unknown"
          fi

          /sbin/uname -S $hostname
        --- 834,845 ----
          # name, default to "unknown"
          #
          if [ -z "$hostname" ]; then
        !       hostname="`shcat /etc/nodename 2>/dev/null`"
        !
        !       if [ -z "$hostname" ]
        !       then
        !              hostname="unknown"
        !       fi
          fi

          /sbin/uname -S $hostname
        END_OF_PATCH

Or do it manually if you want.

  - Logan
--
"Our grandkids love that we get Roadrunner and digital cable."
(Adverti*t for Time Warner cable TV and internet access, July 2001)

 
 
 

DHCP Client Hostname Issue

Post by destroyedlol » Fri, 07 Sep 2001 18:10:14





> >Is there any way to define a hostname for a DHCP client machine... The
> >DHCP server here doesn't push one out so Ialways have unknown, which
> >givees me goofy problems.

> Yeah, that is irritating.

As now my worstation work w/ DHCP and all, I will write a FAQ about such
questions. But I need someone to correct my mispelling ...

Lolo (when I have some time)

 
 
 

DHCP Client Hostname Issue

Post by gary drummon » Sat, 22 Sep 2001 03:59:04






> > >Is there any way to define a hostname for a DHCP client machine... The
> > >DHCP server here doesn't push one out so Ialways have unknown, which
> > >givees me goofy problems.

> > Yeah, that is irritating.

> As now my worstation work w/ DHCP and all, I will write a FAQ about such
> questions. But I need someone to correct my mispelling ...

> Lolo (when I have some time)

man dhcpagent

For some, entering the host name desired in /etc/default/dhcpagent works.
.
.
CLIENT_ID="my-host-name"
.
.

Gary

 
 
 

1. Newbie: DSL Router (& DHCP server) and 'client hostname' for Linux

I have 3 computers (1 NT, 1 Linux RH 7.2, and 1 Linux RH 6.2) in my
household, all of them being connected to a router (Linksys BEFSR41)
to share an ADSL connection for Internet access. I can browse the
Internet from any of them.

For a couple of days I've been struggling with setting up a Samba
server on one of the Linux machines and I have ran into this problem
that the server's name cannot be solved from any of my machines
(including the one that runs the server :-(). If I look at the 'DHCP
clients table' in my router I cannot identify by 'client hostname' any
out of 3 clients but the one running Win NT. It seems as if the Linux
clients fail (or skip) to register their host name after they have
obtained the IP from the DHSP server. The log messages in the
/var/log/messages that I think may indicate some bad setting are in
the listing below

"
...
11:24:32 sofia network: Bringing  up interface eth0:  succeeded
11:24:32 sofia xinetd[987]: failed to parse localhost [line=10]
...
11:24:37 sofia checkpc[1003]:  Get_local_host: hostname 'sofia' bad
11:24:37 sofia lpd[1006]:  Get_local_host: hostname 'sofia' bad
11:24:37 sofia lpd:  2002-09-15-11:24:37.021 Get_local_host: hostname
'sofia' bad
11:24:37 sofia lpd:  lpd startup succeeded
...
"

I am a newbie with Linux so I am asking for help. Does anyone have an
idea on how to interpret the messages above, or how to configure the
Linux so that it registers its hostname with the router.
Thank you

Peter

2. Sony SuperStation.

3. Linksys "DHCP Clients Table" doesn't show hostname

4. AIT Tape jukebox

5. hostname and dhcp client

6. System Admin Metrics (human)

7. Gnome using DHCP client and hostname resolver problem using RH 6.2

8. Page counters

9. Begging for mercy - Samba as DHCP Client - Hostname problem?

10. hostname value lost after second NIC dhcp client gets 2nd IP

11. Simple DHCP client .and associated hostname question....

12. How to use hostname to connect to a DHCP client machine?

13. assigning hostnames to dhcp clients