Find the answer to your Linux question:
Results 1 to 10 of 10
have no idea what went wrong.. hopefully you experts here can lend an advice or 2... aparently my Redhat Linux 9's named service decides to not start and give me ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jul 2004
    Posts
    7

    Urgent.. Please come in.. Weird Problem


    have no idea what went wrong.. hopefully you experts here can lend an advice or 2...

    aparently my Redhat Linux 9's named service decides to not start and give me a
    "couldn't find localhost.. name or service not found"

    my project would need me to get my named running and i'm new to Linux so my options to troubleshoot this problem is close to zero.. and so far haven't been able to do so.

    This problem comes in after I move the location of the PC from one to another..using another dhcp connection.. where the DNS server is different... which I suspect is the culprit...

    anothem symtom I notice is when i log in... it'll flash an error

    "could not look up internet address for compaq.. this will prevent GNOME from operating correctly.. it may be possible to correct the problem by adding compaq to the file /etc/hosts"

    anyone can advice on this?
    thanks in advance

  2. #2
    Linux Newbie
    Join Date
    May 2004
    Location
    Boston, MA
    Posts
    246
    Localhost is the name your computer uses to refer to itself sometimes. Open up a text editor as root and open the file /etc/hosts. If this line isn't there, add it:
    Code:
    127.0.0.1              localhost
    (Replace those spaces in between the address and the name with a tab.)

    The /etc/hosts file is a list of computers that you frequently access, linking their names with their IP addresses so that if a computer is in this file, your system doesn't have to use DNS to resolve its IP: it can just look it up in the file. It's not a good idea to have too many entries in here, though, as looking through a long list of hosts every time your system wants to resolve an IP address can be a drain on performance.

    Hope this helps!
    Situations arise because of the weather,
    And no kinds of love are better than others.

  3. #3
    Just Joined!
    Join Date
    Jul 2004
    Posts
    7
    Quote Originally Posted by dan@george
    Localhost is the name your computer uses to refer to itself sometimes. Open up a text editor as root and open the file /etc/hosts. If this line isn't there, add it:
    Code:
    127.0.0.1              localhost
    (Replace those spaces in between the address and the name with a tab.)

    The /etc/hosts file is a list of computers that you frequently access, linking their names with their IP addresses so that if a computer is in this file, your system doesn't have to use DNS to resolve its IP: it can just look it up in the file. It's not a good idea to have too many entries in here, though, as looking through a long list of hosts every time your system wants to resolve an IP address can be a drain on performance.

    Hope this helps!
    Done doing the step you told me..
    but this error still prevail:

    "could not look up internet address for compaq.. this will prevent GNOME from operating correctly.. it may be possible to correct the problem by adding compaq to the file /etc/hosts"

    .. Whereas for the named service.. status change from "localhost not found" to
    "rndc: connect failed: connection refused"

    What should I do next?

  4. #4
    Linux Newbie
    Join Date
    May 2004
    Location
    Boston, MA
    Posts
    246
    I see, is your computer named compaq? You need to edit the /etc/hosts file again, put another tab after localhost, and add the name of your computer. That is, if your computer's name is shuttlecock, the line should look like this:
    Code:
    127.0.0.1       localhost       shuttlecock
    (find out your computer's name by typing "hostname" at the terminal.)

    Does this work out for you?

  5. #5
    Linux Engineer
    Join Date
    Jul 2003
    Location
    Farnborough, UK
    Posts
    1,305
    I got the same error a while back on my gentoo installation when I emerged Gnome 2.6.

    I did just as dan@george says and twas sorted.
    Lansbury's Lido

    thekiadriver on #linuxforums - fleetingly

  6. #6
    Just Joined!
    Join Date
    Jul 2004
    Posts
    7
    Quote Originally Posted by dan@george
    I see, is your computer named compaq? You need to edit the /etc/hosts file again, put another tab after localhost, and add the name of your computer. That is, if your computer's name is shuttlecock, the line should look like this:
    Code:
    127.0.0.1       localhost       shuttlecock
    (find out your computer's name by typing "hostname" at the terminal.)

    Does this work out for you?
    Thanks for the response.. Greatly appreciated!
    Good news is your step solved the login popup error and now I can ping localhost and compaq.. (hooray) plus the named service no longer have the localhost unknown error!

    but bad news is.... the named service still can't start properly with this error - rndc: connect failed: connection refused
    Thanks in advance mate!

  7. #7
    Linux Newbie
    Join Date
    May 2004
    Location
    Boston, MA
    Posts
    246
    The problem you're describing sounds an awful lot like an open bug in Fedora Core, but if you're using Redhat 9 then I don't know what could be wrong. Sorry, but maybe someone else on the forums can help.

  8. #8
    Linux Engineer Giro's Avatar
    Join Date
    Jul 2003
    Location
    England
    Posts
    1,219
    Both gnome and kde like your ip and hostname in /etc/hosts like so
    Code:
    192.168.0.1 HOSTNAME

  9. #9
    Just Joined!
    Join Date
    Jul 2004
    Posts
    7
    Quote Originally Posted by Giro
    Both gnome and kde like your ip and hostname in /etc/hosts like so
    Code:
    192.168.0.1 HOSTNAME
    yeap I done that

    but bad news is.... the named service still can't start properly with this error - rndc: connect failed: connection refused

    Any resolution to this? Really at my wit's end already

  10. #10
    Linux Guru kkubasik's Avatar
    Join Date
    Mar 2004
    Location
    Lat: 39:03:51N Lon: 77:14:37W
    Posts
    2,396
    dont give up, this is the spirit of open source, but i would recommend looking at some of your router seetings, i had the same error for a while, and realized that i was stupid enought to not have added my linux box to the list of safe MAC addresses......sad i know, but see if its something simple like that or a firewall issue....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •