Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FreeBSD small intranet

Status
Not open for further replies.

khinester

IS-IT--Management
Jul 24, 2003
72
FR
Hello,
I have a web server, running Apache and Zope on a FreeBSD server. What I would like to understand is what should be the steps of configuring this server so that I can just link it to 3 laptops and for these laptops to be used to demo the application within the local environment.

The way I see it is that I have to do:

1) Change the NIC on the server to say, for example:

IP 192.168.0.1
Netmask 255.255.255.0
Gateway (not sure) should this be 192.168.0.1?

DNS: 192.168.0.1 - is this correct?

2) change the /etc/hosts file and add the following entries:

192.168.0.1 server
192.168.0.2 laptop_1
192.168.0.3 laptop_2
192.168.0.4 laptop_3

3) The laptops are all running XP - not sure what to configure here - is there a windows hosts file - or can I just change the TCP/IP properties on the network card so that:

for laptop_1

IP 192.168.0.2
Netmask 255.255.255.0
Gateway 192.168.0.1

DNS 192.168.0.1

4) The application is running Apache and has 9 virtual hosts using a rewrite rule to access sites on a zope server - so:

<VirtualHost *:80>
ServerName subsite_1.server
RewriteEngine On
RewriteRule ^/(.*) [QSA,P]
</VirtualHost>
<VirtualHost *:80>
ServerName subsite_2.server
RewriteEngine On
RewriteRule ^/(.*) [QSA,P]
</VirtualHost>


For the ServerName, do I just put the IP address of the machine, as I am not using DNS

# If your host doesn't have a registered DNS name, enter its IP address here.
# You will have to access it by its address anyway, and this will make
#/ redirections work in a sensible way.
#
ServerName 192.168.0.1:80


or do I put

ServerName server

So if I type on the URI: subsite_1.server the webpage should open the zope site on the 192.168.0.1 server (well thats the plan!)

I don't want to use BIND or any other complicated stuff - simple is good!

Will this sort of thing work, any thoughts or is there a better way to achive the desired outcome.

Comments and suggestions much appreciated.

Cheers

Norman
 
The way I would handle it is this:

1. Assign address 192.168.1.1 to your interface.
(Forget the Ip subnet zero stuff..It's going to cause
problems)

2.Configure your bsd box as a dhcpd server
with scope 192.168.1.2-25. The ISC dhcpd server is
standard, easy to use, and should be available in ports.

3. Use either hosts or dns as your naming method. Internal
dns is easy to configure and more flexible. Bind IS simple.
If you need help I could post a named.conf and a forward zone file.

4. You don't manually configure your clients: Let dhcp
do that.
 
Hi, and thanks for the quick response. I wanted to get away from using DHCP on the server as this will only be used for a 4 day exhibition server and after that will be back on the rack as our development/backup server, so didn't really wanted to add/configure and thne having to remove any more applications.

Although I am toying with the idea of using an Airport base station and let this handle the DHCP - but before I reach this stage, I wanted to get this working the 'normal'way ;^)

Anyhow, would my method be OK, (taking into account the subnet 0 comment you made - by the way why would this cause a problem?)

Would I still need to change the hosts files on the laptops? If so where are they located, and is it a good idea?

Cheers

Norman
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top