LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   /etc/hosts, hostname, and dnsdomainname questions (https://www.linuxquestions.org/questions/linux-software-2/etc-hosts-hostname-and-dnsdomainname-questions-180079/)

rdmenotte 05-10-2004 05:06 PM

/etc/hosts, hostname, and dnsdomainname questions
 
ok, so I have a question or 3 :-)

I am running gentoo linux 2.4.25

for the rest of this thread, my host name is <hostname> and domain name is <domain>


I have set hostname to <hostname> and set dnsdomainname to <domain> but when I am at a login prompt, it shows

<hostname>.unknown_domain

I know that if the following is in /etc/hosts it will display properly:

127.0.0.1 <hostname>.<domain> localhost

but I am thinking that if everything is really working, it should show my hostnamd and domain name both on the login without using the hosts file...

elvisious 05-10-2004 08:25 PM

Whats in /etc/sysconfig/network ?

Try

HOSTNAME=<hostname>.<domain>

Gr
Dion

rdmenotte 05-11-2004 08:06 PM

I do not have /etc/sysconfig.

I am running Gentoo Linux 2.4.25

mardanian 05-11-2004 11:39 PM

well do ask from gentoo gurus at irc.freenode.net ; #gentoo
they will probably help you faster :)

GraemeK 05-12-2004 03:42 AM

whats in your /etc/resolv.conf file?

I'm no expert but i think you need to have this file configured too.

Graeme.

rdmenotte 05-13-2004 10:17 PM

has

domain <mydomain> if that is what you are asking.
It also has other info like my dns servers etc

crm 10-09-2004 05:14 PM

i still havent fixed this problem
all the domain name refrences point to coreline.local
it still comes up as hostname.unknowen-domainname
:'(

Code:

bash-2.05b# cd /usr/src/linux
bash-2.05b# make
make[1]: `arch/i386/kernel/asm-offsets.s' is up to date.
  CHK    include/linux/compile.h
dnsdomainname: Unknown host
Kernel: arch/i386/boot/bzImage is ready
  Building modules, stage 2.
  MODPOST

^ the kernel recompile error i mentioned before

crm 10-09-2004 05:17 PM

also:
Code:

bash-2.05b# cat /etc/resolv.conf
nameserver 192.168.9.11
nameserver 192.168.9.33
search coreline.local


crm 10-10-2004 04:30 AM

boath scripts run correctally at start up...
pleese help i have no idea why it shouldent work :(

satishsverma 03-28-2015 04:27 AM

Please try this step:

for ex. system Lan ip is = 10.7.60.12

than open /etc/hosts file and enter this entry

10.7.60.12 <hostname>.<domain> <hostname>

save and restart your service.


All times are GMT -5. The time now is 08:52 AM.