You are not logged in.
Hi.. i've just setup a local server that i use (with my office mates) for developing webapps..
I used firestarter as firewall and all the rules are right setted.
This is my /etc/hosts
# /etc/hosts: static lookup table for host names
#
#<ip-address> <hostname.domain.org> <hostname>
127.0.0.1 archBox.localdomain archBox
127.0.0.1 localhost.localdomain localhost
100.41.27.5 archbox.localdomain archbox
100.41.27.2 eeeBox.localdomain eeeBox
100.41.27.1 simone.localdomain simone
100.41.27.3 daniele.localdomain daniele
# End of fileI've mapped my localhost with 2 domain name.. i know that it's not so common, but i think that's nothing wrong with that. However, this is not the question.
I need to ssh to my server, so i've added this line to /etc/hosts.allow
sshd: eeeBox, daniele, simone, elioand added in firestarter the rules for allowing eeeBox, daniele, simone, elio to access the sshd service (NOTE: I've used the hostname defined in /etc/host)
If i try to connect to ssh, the connection fail. But if i modify hosts.allow wiith this line
sshd: eeeBox, daniele, simone, elio, 100.41.27.3, 100.41.27.1now daniele, simone successufully connect to sshd service!
It looks like the system couldn't resolve the hostname that i've put inside hosts.allow.
Why i can't use the hostname declared in /etc/hosts for hosts.allow?
On the server i've installed dnsmasq also..
I'hope you understand me ![]()
Offline
shouldn't you be using another column in /etc/hosts like this?
#<ip-address> <hostname.domain.org> <hostname> (i guess from now on are just aliases which you may want)
127.0.0.1 archlinux.domain.org localhost.localdomain localhost archlinux
http://wiki.archlinux.org/index.php/HOS … e_hostname
Last edited by quarkup (2009-11-20 10:35:36)
If people do not believe that mathematics is simple, it is only because they do not realize how complicated life is.
Simplicity is the ultimate sophistication.
Offline
Ok, now /etc/host it's in the right way..
But, again, i want to know why i can't use domain name (defined in /etc/hosts) instead of IP in /etc/hosts.allow..
Offline
Ok, i've got it!
the correct /etc/hosts
#<ip-address> <hostname.domain.org> <hostname>
127.0.0.1 archBox.domain.org localhost.localdomain localhost archBox
100.41.27.2 eeeBox.localdomain eeeBox
100.41.27.1 simone.localdomain simone
100.41.27.3 daniele.localdomain daniele
# End of fileand the correct /etc/host.allow (i need to specify the domain)
#
# /etc/hosts.allow
#
sshd: .localdomain :ALLOW
cvs: .localdomain : ALLOW
swat: .localdomain : ALLOW
mysqld: .localdomain : ALLOW
mysqld-max: .localdomain : ALLOW
# End of fileOffline