>I build a samba file server for my Windows Network (95,98 and NT), I use
myhome.com 
>as my domain and assign addresses in the 192.168.1.xxx class. I put all the
names and 
>ip addresses of all the computers in the /etc/hosts file on the samba server.
I point all 
>the other machines to the samba box for dns services and to make doubly sure I
fill the 
>host.sam file on the windows boxes with the same info as in the the linux
/etc/hosts. I 
>am not running bind or any other dns software.

Without DNS (the program "bind") running on the Samba server, you can NOT
point any computer's (be it Windows 95/98/NT/Linux, etc) DNS settings to 
use the Samba machine.  The /etc/hosts file is NOT the same thing as the 
Bind program.  The /etc/hosts file is ONLY used by the local Unix machine's
programs internally.

Also.. the Windows95 file c:\windows\hosts.sam is only a SAMple file.
For windows to use it, you must RENAME it to just "hosts" and reboot.
With this in place, you will be able to ping, by name, all hosts
defined in that c:\windows\hosts file.  BUT.. Internet access will
still not work properly.


>I make sure to setup all windows boxes to use the linux 
>boxes eth0 (internal network) as it's default gateway. The only rules I use
for ipfwadm are
>ipfwadm -F -p deny
>ipfwadm -F -a m -S192.168.1.0/24 -D 0.0.0.0/0

Thats fine for a first wack but do this insteasd (notice the space
between -S and 192 and the -W command.

ipfwadm -F -p deny
ipfwadm -F -a m -S 192.168.1.0/24 -D 0.0.0.0/0 -W eth1

Later.. I highly recommend to impliment a stronger IPFWADM
ruleset like the one from the MASQ WWW page or my TrinityOS doc.


>If I try using the names of the machines with ping, it fails, ie if I type 
>ping sambabox from the win98 box, it fails with host unknown, if I type ping
192.168.1.2, 
>the ping works fine. Then if I type the ping win98box, the ping works fine
just as it does >if  I type ping 192.168.1.6. 

This is because you need to rename the hosts.sam to hosts and then reboot.
Also.. do NOT configure your Windows machines to use the Linux box as a DNS
server unless you configure bind on the Linux box.  Setting up DNS and many
other
topics are documented in the TrinityOS doc.


>If i run the same 2 pings (using the names) on the linux machine, all 
>works as it should.

This is because of the /etc/hosts file working as it should.


>If I then go back to the the win98 box and ping a known site on the net using
its ip 
>address I instantly get back request timed out, if I then use the name of this
site, it >sits  there for about a minute or 2 then comes back with unknown
host.

This is because your Windows machines are trying to use DNS services
from the Linux box.  But the Linux box isn't running Bind.  If you aren't
interested in running bind on the Linux box, configure the Windows boxes
to use the DNS servers provided from your ISP.  Also configure these
same DNS servers in the /etc/resolve.conf file on the linux box.


>Looking in the /etc/resolv.conf file I see the dns server info as assigned by
dhcp.

I don't beleive DHCP will modify your /etc/resolv.conf file.  This
file is statically configured.

Ps.  If you are interested, the TrinityOS doc can be found here:

        http://www.ecst.csuchico.edu/~dranch/LINUX/TrinityOS.wri

--David
.----------------------------------------------------------------------------.
|  David A. Ranch - Remote Access/Linux/PC hardware      [EMAIL PROTECTED]  |
!----                                                                    ----!
`----- For more detailed info, see http://www.ecst.csuchico.edu/~dranch -----'
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For daily digest info, email [EMAIL PROTECTED]

Reply via email to