# typing "gen2kray" in browsers USED to work....

## kraylus

i had it set so that typing gen2kray in browsers on any machine on the network would load the apache page i have hosted on my gentoo box.

i dont recall what i did (i changed something in /etc/hosts i think) and now it doesnt work. the only way to access the apache server is via the IP (clunky for most of the users in my home.)

here is what my settings are!

/etc/hosts:

```
127.0.0.1              localhost

192.168.123.161   gen2kray.kraylus.com
```

(kraylus.com is registed - but gen2kray.kraylus.com isn't)

now that i look at the file i see that i added this as stated in another forum to increase the responsiveness of X (apps that access the internet anyways.) it was for people who have DHCP (like me) on their gentoo box and as such do not have a static IP.

```
source /etc/dhcpc/dhcpcd-eth0.info  #where eth0 is your nic

$IPADDR [hostname]
```

i commented that out and set it back to what i had before.

EDIT: the reason i commented that out was because it never worked  :Wink: 

in /etc/hostname i simply have gen2kray.kraylus.com

i've switched things around from gen2kray.kraylus.com to just gen2kray. it still doesnt work. anyone know why?

btw, the ServerName in apache.conf is commented out. i figured that might be the culprit but it wasn't. i changed it to specify gen2kray and no dice. 'sides, i don't ever recall UNcommenting it in the first place.

thanks!

----------

## kraylus

btw... im not sure it matters, but i dont have apache configged to run at boot time. i run it manually (and will continue to do so til i t works right.)

does this matter?

----------

## kraylus

i figured it out...

it only works if i have the samba daemon running...

lame!

ryan

----------

## mksoft

 *kraylus wrote:*   

> i figured it out...
> 
> it only works if i have the samba daemon running...
> 
> lame!
> ...

 

Not so lame. The machines are probably using WINS for name resolution (since you have no DNS entry for that machine).

----------

## kraylus

interesting. is there a way to do that without having samba running? perhaps to run my own dns server? can i even do that?? (the ability to run a webserver is boggling enough... but could i really run my own DNS??? as in ns1.kraylus.com)

*drools*

----------

## mksoft

 *kraylus wrote:*   

> interesting. is there a way to do that without having samba running? perhaps to run my own dns server? can i even do that?? (the ability to run a webserver is boggling enough... but could i really run my own DNS??? as in ns1.kraylus.com)
> 
> *drools*

 

You can run your own DNS server (lots of reading up to do, though).

Alternativley, you can put ip and name of the machine in each machine's hosts file (on win9X is c:\windows\hosts, on NT/2000 look it up - if I recall it's in c:\winnt\system32\drivers\etc, but don't count on it - better look it up), and on linux machines in /etc/hosts  :Smile: 

----------

