Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Here's my situation. I have 7 computers. One is only Smoothwall. I have my external modem connected to it. I have an 8 port switch where all 7 computers connect. Three of the PCs have Windows (95, 98, 2000) and the other 3 have Linux (Zipslack, Slackware 9.0, and Red Hat 8.0).
Smoothwall, as I understand it, and as it is currently set up, is acting as a DHCP server. So it randomly assigns an IP (from a range that I gave it at initial setup) to the computers in the system. This Red Hat machine is currently 192.168.0.56. I think it was 192.168.0.55 just the other day. And, I assume that just sort of depends on which order I start up the machines in the morning. (note: for this discussion let's just assume I can't leave the machines on all of the time and also assume that the machines won't be started up in the same order from day to day, and I won't be assigning static IP addresses.) I can connect to the internet from any machine on my system through the Smoothwall machine. And, once connected, I can access the internet from any machine on my system.
Now, of course, I want each machine on my system to be able to share files and printers with the other machines, so I will use Samba for that. However, since each machine may have a different IP address from day to day, I think I need to setup DNS on my system before I can use Samba. Is that right?
Let's say I want my system to be mysystem.com. So I will have, say, L1, L2, L3.mysystem.com and W95, W98, W2K.mysystem.com. In order for my little network to 'share', each machine has to know about L1, L2, L3, W95, W98, and W2K in mysystem.com, since they won't know about 192.168.0.nnn for each machine because of the DHCP, right?
So. My next step seems to be to learn DNS. And, should the DNS 'server' be setup on the Smoothwall machine or on one of the other Linux machines? Isn't DNS really 'bind'? Does bind have to be running on each machine, or just the machine acting as the server?
Any other insight regarding this for my situation?
However, since each machine may have a different IP address from day to day, I think I need to setup DNS on my system before I can use Samba. Is that right?
[/B]
I don't think so. Samba does not require DNS (although it can use it).
Regarding the rest (see: I don't know the Smoothwall) of the matters. My advices are following:
1. use DHCP but assign the constant IPs for each machine; it can be achieve using MAC addresses in the dhcpd.conf
2. setup samba with domain name 'mysystem.com'
3. define your machines in /etc/hosts (use short & full name like W98 & W98.mysystem.com)
3. use DHCP to set samba as WINS server
Thinking about DNS makes sense when:
a. you plan to setup apache - it allows you to use http://apache_box.mysystem.com against http://192.168.0.x
b. you plan to share the files of the server box in a way other than using smb protocol
c. the server works as gateway for the rest of the LAN boxes - but this case you should setup a cashing DNS rather than authoritative one.
Originally posted by dorian33 1. use DHCP but assign the constant IPs for each machine
OK, so I can use the DHCP on the Smoothwall/router machine to give each computer on the system an IP address and manage those addresses from Smoothwall? I didn't know that DHCP would use static IP addresses.
I would like to avoid having to keep the IP addresses from all the other machines on each machine. Which I think means I don't want to maintain hosts.allow and hosts.deny files on all the computers. DHCP is supposed to be the thing that avoids that, right?
Also, I realize that Samba doesn't require DNS, but it does if I use dynamic IP assignments from DHCP, right?
Re: Re: Re: DHCP is setup. Now, DNS before Samba??
Quote:
Originally posted by itsjustme OK, so I can use the DHCP on the Smoothwall/router machine to give each computer on the system an IP address and manage those addresses from Smoothwall? I didn't know that DHCP would use static IP addresses.
If you are editing the dhcp.conf file by hand, you simply add a host directive for every computer that pairs the Mac number with the IP address desired.
I would like to avoid having to keep the IP addresses from all the other machines on each machine. Which I think means I don't want to maintain hosts.allow and hosts.deny files on all the computers. DHCP is supposed to be the thing that avoids that, right?
Not really. All DHCP does is provide address to all those that ask of it. hosts.allow and hosts.deny are security related files. Perhapes you meant /etc/hosts which does contain a list of addresses independently of the DNS.
Quote:
Also, I realize that Samba doesn't require DNS, but it does if I use dynamic IP assignments from DHCP, right?
thanks....
Not really. SMB communicates across the broadcast channel to discover where everyone is, who they are, and what toys they are sharing on the network. However, this information is ONLY known to Samba under unix. (Windows, though, can use this information instead of DNS lookups for webserver, SSH, etc.)
If you plan on doing any kind of serious filesharing I recommend looking into fixing IP addresses through the DHCP server. It does make life awfully simple. At that point maintaining an /etc/hosts file on each machines is cake. (Or just make on /etc/hosts file and copy it to the other stations through scp whenever you make a change.)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.