Welcome to Tech Support Forum home to more then 136,000 problems solved. Issues have included: Spyware, Malware, Virus Issues, Windows, Microsoft, Linux, Networking, Security, Hardware, and Gaming Getting your problem solved is as easy as:
1. Registering for a free account
2. Asking your question
3. Receiving an answer

Registered members:
* Get free support
* Communicate privately with other members (PM).
* Removal of this message
* See fewer ads.
* And much more..

 



Want to know how to post a question? click here Having problems with spyware and pop-ups? First Steps
Go Back   Tech Support Forum > Alternative Computing > Linux Support
User Name
Password
Site Map Register Donate Rules Blogs Mark Forums Read


Linux Support Linux - Operating Systems and Applications Support

Reply
 
LinkBack Thread Tools
Old 01-13-2005, 08:29 AM   #1 (permalink)
Registered User
 
XunilNewb's Avatar
 
Join Date: Jan 2005
Location: UK
Posts: 30
OS: Fedora Core 1, Win XP


Fedora Core 1, LAN, Dhcp server & Internet access (NAT)

Hi there I'm currently setting up a Soho LAN that requires internet access with a view to self hosting a site in the near future.
I have an old Dell Poweredge 2200 running Fedora Core 1, a High spec windows XP machine, a switch and a modem (connected to linux box, as you might expect via serial cable). There are two additional PC's to hook up in the future (one may be used as a DNS server). Well I've done a lot of reading but there are still uncertainties in my mind, does anyone mind if I bombard you with newb questions?

Is the hardware that I have, enough to create a network in which the 2200 Poweredge is both the dhcp server and the internet gateway?

Does the Dell need a fixed ip address in order to allocate ip addresses via dhcp?

If so, what is it that has the fixed ip - is it my nic ie eth0?

Is it best to use ifconfig (ifcfg) to change the ip, what other files need changing?

Can the server (or a machine via the server) connecting to the internet recieve ip info from my isp while acting as a dhcp server. Do I need to purchase a router in order to use NAT? Can I do the same thing using iptables? -- if so how?

*Any* help would be greatly appreciated, cheers guys
XunilNewb is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Important Information
Join the #1 Tech Support Forum Today - It's Totally Free!

TechSupportForum.com is a leading support website for your computer needs. We offer free, friendly and personalized computer support. Why pay to have your computer fixed when you can do it for free.

Join TechSupportforum.com Today - Click Here

Old 01-13-2005, 09:03 AM   #2 (permalink)
Manager, Alternative Comp
 
Skie's Avatar
 
Join Date: Mar 2003
Location: Chicago burbs
Posts: 2,194
OS: Gentoo Linux, CentOS, OS X

My System

I did a quick search and found the specs of this server to be:

Dual PII 300Mhz
128MB RAM
2 2GB hard drives

Is this what you have? If not, please specify. I'm going to assume that this is what you have.

Do you want to use a GUI with this machine? If you do, then I would recommend upgrading both the RAM and Hard Drives if you plan on using either KDE or Gnome. If you use a light weight Desktop Enviroment, then you should be fine. If you're just going to use the command line, you should be fine.

Based on what you've told me, you'll be using a modem for internet connectivity. Your modem/linux will get the dynamic IP from your ISP and assign it to the modem. IPTables will then use NAT to act as a "gateway" between your internal network and the internet.

The first thing I would do is to setup your internal network. You can use either static or dynamic IP's. Just make sure you setup dhcpd on linux if you want to use DHCP. Once you have the internal network set, configure your modem for connectivity to your ISP. How this is done depends on what you'll be installing (Gnome, KDE or command line). If you need more help here, let us know.

Once you're able to connect, it's time to setup your iptables for NAT. You can look at this page for a good explination: http://www.yolinux.com/TUTORIALS/Lin...rkGateway.html. There is a lot of information here, but if you start at the top and work your way down, you should be able to figure it out.
__________________
Skie is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-13-2005, 10:10 AM   #3 (permalink)
Registered User
 
XunilNewb's Avatar
 
Join Date: Jan 2005
Location: UK
Posts: 30
OS: Fedora Core 1, Win XP


TY Skie that is usefull info, more info and questions incomming...

Thanks for your advice (an astonishiongly rapid reply!). The Dell currently has 512KB cache to one PII processor (only one PII chip I'm afraid), 32 MB of 72-bit-wide, buffered EDO-type main memory etc etc.

I installed pretty much all the server options and both KDE and Gnome. As a newb I wanted to check everything out. Things are slow in GUI modes but I'm trying to do everything from the command line. (Essentially I'm just testing stuff out at the mo but I can certainly see myself upgrading my server hardware etc in the future)

I obtained my dhcp.conf file from:

/usr/share/doc/dhcp-3.0pl2/dhcpd.conf.sample

and copied it into my /etc folder --> /etc/dhcpd.conf

I guess I need help understanding the dhcpd.conf file before I tackle iptables.

What has determined these addresses (default settings?) And what do they refer to? Is there an ip address in dhcpd.conf that reffers to my nic?

subnet 192.168.0.0 netmask 255.255.255.0 {

# --- default gateway

option routers 192.168.0.1;
option subnet-mask 255.255.255.0;

range dynamic boot-p 192.168.0.128 192.168.0.254;

--------------------------------------------------------------------------
Does the "#" symbol merely #-out comments in files such as these?

I want to configure a fixed ip for the nic on the linux box (dell), if i do that
with ifcfg do I also need to change / configure that in dhcpd.conf?

Where can I find easy to understand advice on using iptables *gulp*
XunilNewb is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-13-2005, 12:33 PM   #4 (permalink)
Manager, Alternative Comp
 
Skie's Avatar
 
Join Date: Mar 2003
Location: Chicago burbs
Posts: 2,194
OS: Gentoo Linux, CentOS, OS X

My System

You can look at this link for info on setting up dhcpd: http://www.linuxhomenetworking.com/linux-hn/dchp.htm.

If anything is confusing to you, let me know.

Yes, the # means a comment.

If you want to assign a specific IP address to a particular machine, use the following:

Quote:
host <computer name goes here> {
hardware ethernet 08:00:2b:4c:59:23;
fixed-address 192.168.1.222;
}
The "hardware ethernet" is the MAC address of the machine. For linux, you can get this using the ifconfig command.

As far as iptables, there really isn't a whole lot of easy to use tutorials. iptables itself is quite complicated and will take some time and understanding to work with. There are a few GUI based tools that you can use, but I don't know which ones off the top of my head. If you'd like, I'll take a look around.
__________________
Skie is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-13-2005, 01:34 PM   #5 (permalink)
Registered User
 
XunilNewb's Avatar
 
Join Date: Jan 2005
Location: UK
Posts: 30
OS: Fedora Core 1, Win XP


Thumbs Up Thanks again!

Again some great info! Thanks loads Skie, that clears a few things up. If anyone's interested I found some usefull iptables info @ http://www.faqs.org/docs/iptables/
XunilNewb is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-14-2005, 11:27 AM   #6 (permalink)
Registered User
 
XunilNewb's Avatar
 
Join Date: Jan 2005
Location: UK
Posts: 30
OS: Fedora Core 1, Win XP


ip mayhem (and what is next-server in dhcpd.conf?)

when i run ifconfig -a i can see that my HW addr of my ethernet NIC is 00:01:02:E2:76:B5... Aha, so that is my MAC addr?

In order for the server to always appear at a fixed address (router/gateway addr) I need to map it with a host entry

eg

# set dhcp/name server to appear at fixed addr
host ns {
next-server ns1 _____________?
hardware ethernet 00:01:02:E2:76:B5
fixed address 10.0.0.1

Question: What is the "next-server"?

My other question is a more general ip allocation question.

The subnet mask 255.255.255.252 would yield 4 addresses (256-252=4). Does this meen 4 subnets? ie if the host portion of the ip address was 28 then there would be (28/4=7) 7 available addresses in each subnet? Is the ip address in this instance the same as the router/gateway addr ie the one that will be mapped to my NIC as above?

XunilNewb is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-15-2005, 01:24 PM   #7 (permalink)
Manager, Alternative Comp
 
Skie's Avatar
 
Join Date: Mar 2003
Location: Chicago burbs
Posts: 2,194
OS: Gentoo Linux, CentOS, OS X

My System

I'm not familiar with the next-server option. I have a feeling it has something to do with DNS servers, but I've been unable to find an explination of that option. I didn't search extensively though. As far as the subnet mask, stick with 255.255.255.0, and you'll be fine. I don't think you need to narrow down the available IP's unless you specifically want to limit the number of available IP's.
__________________
Skie is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-15-2005, 01:34 PM   #8 (permalink)
Registered User
 
XunilNewb's Avatar
 
Join Date: Jan 2005
Location: UK
Posts: 30
OS: Fedora Core 1, Win XP


next-sever DNS

Cheers Skie, I think you're right, it does have something to do with the allocation of a DNS server - I'll comment that crap out for now and just get the job done.

__________________
Don't worry Scoob, I don't think Thelma literally meant IPtables!
XunilNewb is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Old 01-15-2005, 02:11 PM   #9 (permalink)
Manager, Alternative Comp
 
Skie's Avatar
 
Join Date: Mar 2003
Location: Chicago burbs
Posts: 2,194
OS: Gentoo Linux, CentOS, OS X

My System

You can have your DHCP server set to provide the DNS info. This is what many do. So, unless you want to manually set this on each computer, I would use it. Without this info, your internet access will be severely limited.
__________________
Skie is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




All times are GMT -7. The time now is 09:31 AM.



Copyright 2001 - 2009, Tech Support Forum
Home Tips Plus | Outdoor Basecamp | Automotive Support Forum

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85