LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-04-2006, 01:39 AM   #1
raport
Member
 
Registered: Aug 2004
Location: Legazpi City, Philippines
Posts: 77

Rep: Reputation: 15
How to configure Internet Connection Sharing in Fedora 4


dear friends,

how do you configure internet connection in fedora 4. i tried to use the configuration in redhat 9 but it doesn't work.

thanks for any help

raport
 
Old 01-04-2006, 01:42 AM   #2
timmeke
Senior Member
 
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515

Rep: Reputation: 61
Could you please provide additional information, like:
-how you want to "share" connections (eg via a NAT router, etc)
-how you've accomplished it in RH9
-what exactly you want to do with it
-etc
 
Old 01-04-2006, 03:11 PM   #3
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
Yes, I have no idea how to even begin this. Please, someone help!

http://www.linuxcompatible.org/inter...ng_t33606.html
I found that. Is it any good?

Last edited by dalponis; 01-04-2006 at 03:13 PM.
 
Old 01-05-2006, 01:40 AM   #4
timmeke
Senior Member
 
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515

Rep: Reputation: 61
There are many alternatives. The one discribed on the link you provided may work, in case you have
your internet connection is directly branched to one PC and you that PC is then further connected to
your network via a 2nd network card.

What I'm trying to say is... it really depends on your network's setup (and also somewhat on your internet
setup). So, please give us more details, like
computer 1 is branched to internet
computers 2 and 3 are branched to computer 1 only. I'd like for them to use the internet connection that has
been set up on computer 1.
etc
 
Old 01-05-2006, 05:15 PM   #5
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
Here's my current setup.

Linux Machine:
wlan0
IP: 192.168.1.25
Subnet Mask: 255.255.255.0
Gateway: 192.168.1.1

eth0
IP: 192.168.0.1
Subnet Mask: 255.255.255.0
Gateway: null

Windows Machine:
Local area network:
IP: 192.168.0.2
Subnet Mask: 255.255.255.0
Gateway: 192.168.0.1

I want to forward the internet to my second computer(Windows) from the first(Linux).

I use a cross over cable.

Last edited by dalponis; 01-05-2006 at 06:40 PM.
 
Old 01-05-2006, 09:12 PM   #6
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
const FIRST_PAGE as integer = 1

If postLevel < FIRST_PAGE Then
bump()
End-If
 
Old 01-06-2006, 01:32 AM   #7
timmeke
Senior Member
 
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515

Rep: Reputation: 61
Quote:
Originally Posted by dalponis
wlan0
IP: 192.168.1.25
Subnet Mask: 255.255.255.0
Gateway: 192.168.1.1
Is this wireless connection to your (wireless) internet modem?
I only see 192.168.*.* addresses, which are - by definition - always internal on a network.
For your internet to work, however, one of your machines must have a modem, router, firewall or something that contacts the outside world (your ISP, probably).

If this modem/router/.... provides NAT (network address translation), possibly DHCP and multiple connections, you may be better off hooking both your Linux and Windows boxes to
it directly.

Quote:
Originally Posted by dalponis
eth0
IP: 192.168.0.1
Subnet Mask: 255.255.255.0
Gateway: null
Since you say that you're using a cable, I suppose it's hooked up to eth0 on your Linux box.

Quote:
Originally Posted by dalponis
Windows Machine:
Local area network:
IP: 192.168.0.2
Subnet Mask: 255.255.255.0
Gateway: 192.168.0.1
For your Linux box to act as a gateway, it must be set up for routing (ie it must act as a router).
See:
man route
for that.
 
Old 01-06-2006, 02:09 AM   #8
raport
Member
 
Registered: Aug 2004
Location: Legazpi City, Philippines
Posts: 77

Original Poster
Rep: Reputation: 15
here's what i did which i applied both in redhat9 and Fedora core 4.

the system is this.

8 PC's connects to a hub one of the PC's connects to a modem and internet

for the PC that connects to the internet:

1.edit /etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE=eth0
BOOTPROTO=none
HWADDR=00:04:75:AD:39:E5
ONBOOT=yes
TYPE=Ethernet
IPADDR=192.168.0.1
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
USERCTL=no
PEERDNS=no

2. /etc/sysctl.conf

# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.

# Controls IP packet forwarding
net.ipv4.ip_forward = 1

# Controls source route verification
net.ipv4.conf.default.rp_filter = 1

# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 0

# Controls the System Request debugging functionality of the kernel


kernel.sysrq = 0

# Controls whether core dumps will append the PID to the core filename.
# Useful for debugging multi-threaded applications.
kernel.core_uses_pid = 1

# Controls the use of TCP syncookies

3./etc/sysconfig/network

NETWORKING=yes
HOSTNAME=rporticio.mydomain.com

4. /etc/rc.d/rc.local

touch /var/lock/subsys/local
mount /dev/hdb2 /redhat
iptables -t nat -D PREROUTING -i eth0 -j loc_dnat
iptables -t nat -A POSTROUTING -o ppp+ -j MASQUERADE

5. /etc/resolv.conf DNS of the ISP

search localdomain
nameserver 61.9.19.1
nameserver 61.9.19.2
nameserver 61.9.19.3

for the other PC's in windowsOD and linux I set the gateway to the IP address of the PC connected to the modem.

this works fine in redhat9 as OS of the PC connected to internet but very slow in fedore core 4 as of of the PC connected to the internet.

i just wondered why.

thanks for any help.

raport
 
Old 01-06-2006, 02:13 AM   #9
raport
Member
 
Registered: Aug 2004
Location: Legazpi City, Philippines
Posts: 77

Original Poster
Rep: Reputation: 15
dear friends,

here's what i did which i applied both in PC having redhat9 and Fedora core 4 OS.

the system is this.

8 PC's connect to a hub and one of the PC's connects to a modem and to internet.

For the PC that connects to the internet:

1.edit /etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE=eth0
BOOTPROTO=none
HWADDR=00:04:75:AD:39:E5
ONBOOT=yes
TYPE=Ethernet
IPADDR=192.168.0.1
NETMASK=255.255.255.0
NETWORK=192.168.0.0
BROADCAST=192.168.0.255
USERCTL=no
PEERDNS=no

2. /etc/sysctl.conf

# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.

# Controls IP packet forwarding
net.ipv4.ip_forward = 1

# Controls source route verification
net.ipv4.conf.default.rp_filter = 1

# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 0

# Controls the System Request debugging functionality of the kernel


kernel.sysrq = 0

# Controls whether core dumps will append the PID to the core filename.
# Useful for debugging multi-threaded applications.
kernel.core_uses_pid = 1

# Controls the use of TCP syncookies

3./etc/sysconfig/network

NETWORKING=yes
HOSTNAME=rporticio.mydomain.com

4. /etc/rc.d/rc.local

touch /var/lock/subsys/local
mount /dev/hdb2 /redhat
iptables -t nat -D PREROUTING -i eth0 -j loc_dnat
iptables -t nat -A POSTROUTING -o ppp+ -j MASQUERADE

5. /etc/resolv.conf DNS of the ISP

search localdomain
nameserver 61.9.19.1
nameserver 61.9.19.2
nameserver 61.9.19.3

for the other PC's in windowsOS and linux I set the gateway to the IP address of the PC connected to the modem.

this works fine in redhat9 as OS of the PC connected to internet but very slow internet connectivity in fedora core 4 as OS of the PC connected to the internet.


i just wondered why?

thanks for any help.

raport

Last edited by raport; 01-06-2006 at 03:02 AM.
 
Old 01-06-2006, 03:06 AM   #10
timmeke
Senior Member
 
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515

Rep: Reputation: 61
So, it actually works but is just slower then it should be?
That can depend on a lot of issues. Have you tried things like traceroute (on the non-internet connected hosts) or a packet capturing tool (on the internet connected machine), just to see what's happening.
Are you sure nothing else is slowing down your FC machine? Eg other processes, other daemons, etc (try "top")?
Furthermore, your FC machine is hooked up to the internet via a wireless connection. Are you sure it's configured for maximum speed (ie in the same way as on your old box)? Since your FC machine "forwards" the internet connection to all your other machines, it may just be your internet setup that's causing the delays.
You could try this by browsing a few sites on the FC machine, for instance.

As to the actual configuration, I'm just a newbie, so you might want to ask the moderator to put this thread in the Linux - Networking forum.
 
Old 01-07-2006, 12:04 AM   #11
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
Well, I tried what you guys suggested. The internet does not get forwarded. My Windows machine does not surf the net...

Do you have more questions about my setup? Yes, the wlan0 is my wifi connnection to the router. Yes, the eth0 is the cross over connection to my Windows machine.

Last edited by dalponis; 01-07-2006 at 10:29 AM.
 
Old 01-07-2006, 10:30 AM   #12
dalponis
Member
 
Registered: Jan 2006
Location: Alberta, Canada
Distribution: Fedora 19 x86_64
Posts: 96

Rep: Reputation: 15
I've started a new thread... As this one isn't really mine.

I'm using Arno's IPTables-Firewall Script now.

Last edited by dalponis; 01-07-2006 at 04:01 PM.
 
Old 01-08-2006, 06:46 PM   #13
raport
Member
 
Registered: Aug 2004
Location: Legazpi City, Philippines
Posts: 77

Original Poster
Rep: Reputation: 15
before trying to look into your suggestions, i changed the gateway of my PC with fedora 4 OS that is formerly connected to the internet to the IP address of another PC with Redhat9 OS. This PC(with redhat 9 OS) is now connected to the internet. Suddenly, internet surfing speed in fedora 4 is greatly improved! But this does not solve the problem, for i think fedora 4 should even have more capability in speed as a gateway being a new and upated linux OS than the older redhat9.

Last edited by raport; 01-08-2006 at 06:51 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Internet Connection Sharing - Windows XP Home to Fedora 2 Covenent Linux - Networking 12 11-05-2006 06:57 PM
How do I set up Internet Connection Sharing on fedora core 1? milkrock Linux - Networking 7 01-29-2006 04:52 AM
Sharing Internet Connection Windows <- Linux (Fedora Core 3) e6x Linux - General 7 08-03-2005 12:58 PM
Unable to configure internet connection in Fedora sathya82 Linux - Networking 0 07-03-2004 08:21 PM
sharing internet connection between Fedora host and Win98 VMware guest NGShake Linux - Software 2 12-20-2003 12:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 01:55 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration